Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

main: display an error message instead of panic when setup fails #284

merged 1 commit into from Sep 13, 2018


None yet
2 participants
Copy link

commented Sep 13, 2018

lazygit is not a library, but jsut CLI for end users. So it does not need to raise panic when config/setup fails.

For example, if I run lazygit in non-git directory, I'll get a following result:

panic: fatal: not a git repository (or any of the parent directories): .git

goroutine 1 [running]:
	/go/src/ +0x470

It seems like a bug! We can just show error message without panic, like this:

2018/09/14 00:29:55 fatal: not a git repository (or any of the parent directories): .git

This comment has been minimized.

Copy link

commented Sep 13, 2018

LGTM :) Thanks for making this!

@jesseduffield jesseduffield merged commit fa08c6c into jesseduffield:master Sep 13, 2018

4 checks passed

GolangCI No issues found!
ci/circleci: build Your tests passed on CircleCI!
codecov/patch Coverage not affected when comparing eb4b5cd...3cf84a5
codecov/project 91.38% remains the same compared to eb4b5cd

@mingrammer mingrammer deleted the mingrammer:main-error branch Sep 14, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.