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

Use stderr when git command fails #56

Merged
merged 1 commit into from
Apr 4, 2025
Merged

Use stderr when git command fails #56

merged 1 commit into from
Apr 4, 2025

Conversation

ndombroski
Copy link
Contributor

@ndombroski ndombroski commented Apr 3, 2025

Previously, when git commands failed, we weren't capturing stderr in the message, leading to un-descriptive errors such as

17:18:10 main.go:82: can't list dirty packages: diffing directory for dirty packages, exit status 128

I've noticed myself and have seen it pointed out in other issues (such as #45). By capturing stderr, we'll get more helpful errors such as

17:32:30 main.go:82: can't list dirty packages: diffing directory for dirty packages, exit status 128: fatal: not a git repository (or any of the parent directories): .git

@ndombroski ndombroski merged commit f67eabc into master Apr 4, 2025
6 checks passed
@ndombroski ndombroski deleted the git-error-info branch April 4, 2025 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants