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

check breakages: fail loudly when unable to checkout tag #1060

Merged
merged 1 commit into from Jul 9, 2019

Conversation

Projects
None yet
2 participants
@ktoso
Copy link
Member

commented Jul 9, 2019

One line description of your change

Motivation:

When using the script ad hoc to verify something you may have forgotten to pull all tags,
the script then fails mysteriously in silence and no output. Detective work can then lead the script mysteriously stopping after a checkout:

+ cd /tmp/.check-api_1Q1rvO/repo
+ git checkout 1.1.0
$ ...

which reminds you to perform a fetch; it would be nicer if it told us about the issue explicitly though.

Modifications:

Don't silence git checkout all error output, though use quiet mode so no progress is printed.

Result:

Script fails nicer and reminds you to perform a git fetch if you forgot to do so.

e.g.

[5/5] Merging module Metrics
error: pathspec '1.1.0' did not match any file(s) known to git
check breakages: fail loudly when unable to checkout tag
One line description of your change

Motivation:

When using the script ad hoc to verify something you may have forgotten to pull all tags,
the script then fails mysteriously in silence and no output. Detective work can then lead the script mysteriously stopping after a checkout:

```
+ cd /tmp/.check-api_1Q1rvO/repo
+ git checkout 1.1.0
$ ...
```

which reminds you to perform a fetch; it would be nicer if it told us about the issue explicitly though.

Modifications:

Don't silence `git checkout` all error output, though use quiet mode so no progress is printed.

Result:

Script fails nicer and reminds you to perform a git fetch if you forgot to do so.

e.g.

```
[5/5] Merging module Metrics
error: pathspec '1.1.0' did not match any file(s) known to git
```
@weissi

weissi approved these changes Jul 9, 2019

Copy link
Member

left a comment

Thank you!!

@weissi weissi merged commit ed3bca3 into apple:master Jul 9, 2019

2 checks passed

pull request validation (5.0) Build finished.
Details
pull request validation (5.1) Build finished.
Details

@ktoso ktoso deleted the ktoso:patch-3 branch Jul 10, 2019

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.