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 that executable file is in-tree before failing tidy check #35848

Merged
merged 1 commit into from Aug 22, 2016

Conversation

Mark-Simulacrum
Copy link
Member

I silenced stdout and stderr for ls-files, not sure if that's appropriate (is make tidy intended to give debugging information)? Otherwise it prints each file it find to stdout/stderr, which currently prints nothing (only executable files are checked).

I have not done major testing regarding the behavior of ls-files when the file is ignored, but judging by the man page everything should be fine.

I've duplicated the code which makes the path git-friendly from the Cargo.lock checking code; I can extract that into a common helper if wanted (it's only two lines).

Fixes #35689.

@rust-highfive
Copy link
Collaborator

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @aturon (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@alexcrichton
Copy link
Member

Thanks for the PR! Looks reasonable to me, but can you confirm that this still works by checking in an executable file and running make tidy?

@Mark-Simulacrum
Copy link
Member Author

Fails for me. (I probably wasn't clear in the description--I did a basic check, just not for what happens when the file is ignored or only staged, etc.)

@alexcrichton
Copy link
Member

Perfect, thanks!

@bors: r+ be8df50

eddyb added a commit to eddyb/rust that referenced this pull request Aug 22, 2016
…r=alexcrichton

Check that executable file is in-tree before failing tidy check

I silenced stdout and stderr for ls-files, not sure if that's appropriate (is `make tidy` intended to give debugging information)? Otherwise it prints each file it find to stdout/stderr, which currently prints nothing (only executable files are checked).

I have not done major testing regarding the behavior of ls-files when the file is ignored, but judging by the man page everything should be fine.

I've duplicated the code which makes the path git-friendly from the `Cargo.lock` checking code; I can extract that into a common helper if wanted (it's only two lines).

Fixes rust-lang#35689.
@bors
Copy link
Contributor

bors commented Aug 22, 2016

⌛ Testing commit be8df50 with merge 57a1f68...

bors added a commit that referenced this pull request Aug 22, 2016
Check that executable file is in-tree before failing tidy check

I silenced stdout and stderr for ls-files, not sure if that's appropriate (is `make tidy` intended to give debugging information)? Otherwise it prints each file it find to stdout/stderr, which currently prints nothing (only executable files are checked).

I have not done major testing regarding the behavior of ls-files when the file is ignored, but judging by the man page everything should be fine.

I've duplicated the code which makes the path git-friendly from the `Cargo.lock` checking code; I can extract that into a common helper if wanted (it's only two lines).

Fixes #35689.
@bors bors merged commit be8df50 into rust-lang:master Aug 22, 2016
@Mark-Simulacrum Mark-Simulacrum deleted the make-tidy-in-tree branch September 16, 2016 21:27
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.

None yet

5 participants