question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error codes aren't passed from Git subcommand

See original GitHub issue

🐛 Bug Report

When meta-git fails it doesn’t seem to pass the error code back.

To Reproduce

Steps to reproduce the behavior:

  • Run any invalid Git command meta git blah blah for example.

Expected behavior

Should pass the error back, instead it does nothing.

Current behavior: image

Expected behavior would be something like: image

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
mateodelnortecommented, Feb 9, 2020

And thus we arrive at why it’s currently not the default. 😉

Personally, I’m fine leaving things as is and letting people writing scripts add the extra flags when error codes are required.

On Sun, Feb 9, 2020 at 12:29 PM Ameer A. notifications@github.com wrote:

@mateodelnorte https://github.com/mateodelnorte there could be a downside for setting exit on aggregated error on all subcommands 🤔 say you only have a set of changes on some of the child repos and you wanna commit them, then there would be multiple errors on all child repos that don’t have any change them (since Git doesn’t like it)

Would it be reasonable to assume in such case the usage would have either exclude or include flags set? Or should the command be aware enough not to run in these child repos 🤔

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/mateodelnorte/meta/issues/212?email_source=notifications&email_token=AAEHOX4ZVWPNTGYVHUHMUTLRCBCN3A5CNFSM4KPYSV42YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOELGT5SI#issuecomment-583876297, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAEHOX6BXR5KBEGTTM5OTLDRCBCN3ANCNFSM4KPYSV4Q .

1reaction
mateodelnortecommented, Feb 6, 2020

I think it should be the default for all. Let’s get the PR up and play with it, and we can decide whether it will be breaking or not. *It’s probably breaking tho.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Pass error raised in subcommands to local error handler of its ...
The Problem If several subcommands of a certain group command raises same error, we will have to add local error handler method to...
Read more >
git-help Documentation - Git
Prints a list of the Git concept guides on the standard output. --user-interfaces. Prints a list of the repository, command and file interfaces...
Read more >
Implementing a new "git ..." subcommand as a Python script
I'm trying to make some minor changes to the git p4 subcommand, which is implemented as a 3797-line Python script named /usr/libexec/git-core/ ...
Read more >
picocli - a mighty tiny command line interface
Any command line argument that is not an option or subcommand is interpreted as a positional parameter. Java. Kotlin. String[] args = {...
Read more >
One weird trick for powerful Git aliases - Work Life by Atlassian
Will allow you to type git ls to get a bare list of short commit ids and ... $1 to mean the first...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found