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

build: improve script and travis config #4675

Merged
merged 7 commits into from
Oct 24, 2019

Conversation

tesuji
Copy link
Contributor

@tesuji tesuji commented Oct 16, 2019

  • fix a diff failure on windows

See https://travis-ci.com/rust-lang/rust-clippy/jobs/245971932#L1625
for an example.

  • use cmp instead of diff > /dev/null

  • clone single branch instead of clone then checking out

  • do not decrypt key if have no diff change

changelog: none

Copy link
Member

@flip1995 flip1995 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm really no bash expert, so some questions might seem silly. Most of the changes LGTM.

.github/deploy.sh Show resolved Hide resolved
.github/deploy.sh Show resolved Hide resolved
ci/base-tests.sh Outdated Show resolved Hide resolved
tests/ui-toml/update-all-references.sh Show resolved Hide resolved
@flip1995
Copy link
Member

Oh and thanks for all the work on the build system lately! ❤️


# Make sure this isn't set - clippy-driver should cope without it
unset CARGO_MANIFEST_DIR

# Run a lint and make sure it produces the expected output. It's also expected to exit with code 1
# XXX How to match the clippy invocation in compile-test.rs?
! ./target/debug/clippy-driver -Dwarnings -Aunused -Zui-testing --emit metadata --crate-type bin tests/ui/cstring.rs 2> cstring.stderr
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand what this command does. Could someone explain it to me?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This whole block checks if clippy-driver can be run without cargo.

This command is just a test, if the output of clippy-driver is the same as the output of the ui-test. Why cstring.rs was chosen for this test, I have no idea.

I guess all these flags are there to simulate the behavior of compiletest-rs.

Copy link
Member

@phansch phansch Oct 17, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR that added this has some more context. Maybe include the PR link in the comment?
#3665

ci/integration-tests.sh Outdated Show resolved Hide resolved
@phansch phansch added the S-waiting-on-author Status: This is awaiting some action from the author. (Use `@rustbot ready` to update this status) label Oct 17, 2019
@tesuji tesuji force-pushed the improve-shellscript branch 4 times, most recently from 27e88b6 to 16c2681 Compare October 17, 2019 10:11
@tesuji
Copy link
Contributor Author

tesuji commented Oct 17, 2019

Ready for review!
I sorted out the test failure in cargo-clippy on macOS systems.

@bors
Copy link
Collaborator

bors commented Oct 17, 2019

☔ The latest upstream changes (presumably #4659) made this pull request unmergeable. Please resolve the merge conflicts.

@tesuji tesuji force-pushed the improve-shellscript branch 3 times, most recently from d4f2bba to 33cf02c Compare October 18, 2019 04:09
@phansch phansch added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties and removed S-waiting-on-author Status: This is awaiting some action from the author. (Use `@rustbot ready` to update this status) labels Oct 18, 2019
@tesuji tesuji changed the title build: improve script and travis config [WIP] build: improve script and travis config Oct 19, 2019
@bors
Copy link
Collaborator

bors commented Oct 20, 2019

☔ The latest upstream changes (presumably #4702) made this pull request unmergeable. Please resolve the merge conflicts.

Comment on lines +117 to +119
osx )
# See <https://github.com/nteract/nteract/issues/1523#issuecomment-301623519>
sudo mkdir -p /usr/local/lib
sudo find "$SYSROOT/lib" -maxdepth 1 -name '*.dylib' -exec ln -s {} /usr/local/lib \;
;;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This wasn't necessary before. What changed?

Copy link
Contributor Author

@tesuji tesuji Oct 21, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Honestly, I don't know. I tried to set LD_LIBRARY_PATH, LIBRARY_PATH, DYLD_LIBRARY_PATH. All of that still made this PR failed.

ci/base-tests.sh Outdated Show resolved Hide resolved
@tesuji tesuji force-pushed the improve-shellscript branch 4 times, most recently from f2ffc3d to 44c3c9c Compare October 21, 2019 08:09
* fix a diff failure on windows

See https://travis-ci.com/rust-lang/rust-clippy/jobs/245971932#L1625
for an example.

* use cmp instead of diff > /dev/null

* clone single branch instead of clone then checking out

* do not decrypt key if have no diff change
@tesuji tesuji changed the title [WIP] build: improve script and travis config build: improve script and travis config Oct 22, 2019
@tesuji
Copy link
Contributor Author

tesuji commented Oct 22, 2019

Build succeed. I wanna more eyes and thoughts on #4675 (comment).

@phansch
Copy link
Member

phansch commented Oct 23, 2019

@bors try

bors added a commit that referenced this pull request Oct 23, 2019
build: improve script and travis config

* fix a diff failure on windows

See https://travis-ci.com/rust-lang/rust-clippy/jobs/245971932#L1625
for an example.

* use cmp instead of diff > /dev/null

* clone single branch instead of clone then checking out

* do not decrypt key if have no diff change

changelog: none
@bors
Copy link
Collaborator

bors commented Oct 23, 2019

⌛ Trying commit 088d528 with merge 23a5fce...

@tesuji
Copy link
Contributor Author

tesuji commented Oct 23, 2019

Note that in the first try, the cache will be invalidated because of removing BASE_TESTS env.

@bors
Copy link
Collaborator

bors commented Oct 23, 2019

☀️ Try build successful - checks-travis, status-appveyor
Build commit: 23a5fce (23a5fce1a82eed9ea57887021901b0c5ad5eb89b)

@phansch
Copy link
Member

phansch commented Oct 23, 2019

@bors try

@bors
Copy link
Collaborator

bors commented Oct 23, 2019

⌛ Trying commit 088d528 with merge 5db053f...

bors added a commit that referenced this pull request Oct 23, 2019
build: improve script and travis config

* fix a diff failure on windows

See https://travis-ci.com/rust-lang/rust-clippy/jobs/245971932#L1625
for an example.

* use cmp instead of diff > /dev/null

* clone single branch instead of clone then checking out

* do not decrypt key if have no diff change

changelog: none
@bors
Copy link
Collaborator

bors commented Oct 23, 2019

☀️ Try build successful - checks-travis, status-appveyor
Build commit: 5db053f (5db053f5de87553cd5a80a705ceaea2b2cd125b4)

@phansch
Copy link
Member

phansch commented Oct 24, 2019

Changes look good to me. I can't say anything about the dylib stuff, but it seems to work fine 🤷‍♂️

Thanks for all your build improvements!

@bors r+

@bors
Copy link
Collaborator

bors commented Oct 24, 2019

📌 Commit 088d528 has been approved by phansch

@bors
Copy link
Collaborator

bors commented Oct 24, 2019

⌛ Testing commit 088d528 with merge 87536f0...

bors added a commit that referenced this pull request Oct 24, 2019
build: improve script and travis config

* fix a diff failure on windows

See https://travis-ci.com/rust-lang/rust-clippy/jobs/245971932#L1625
for an example.

* use cmp instead of diff > /dev/null

* clone single branch instead of clone then checking out

* do not decrypt key if have no diff change

changelog: none
@bors
Copy link
Collaborator

bors commented Oct 24, 2019

☀️ Test successful - checks-travis, status-appveyor
Approved by: phansch
Pushing 87536f0 to master...

@bors bors merged commit 088d528 into rust-lang:master Oct 24, 2019
@tesuji tesuji deleted the improve-shellscript branch October 24, 2019 08:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants