File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ branches:
1717env :
1818 global :
1919 - RUST_BACKTRACE=1
20+ - secure : " OKulfkA5OGd/d1IhvBKzRkHQwMcWjzrzbimo7+5NhkUkWxndAzl+719TB3wWvIh1i2wXXrEXsyZkXM5FtRrHm55v1VKQ5ibjEvFg1w3NIg81iDyoLq186fLqywvxGkOAFPrsePPsBj5USd5xvhwwbrjO6L7/RK6Z8shBwOSc41s="
2021
2122install :
2223 - |
@@ -88,6 +89,20 @@ matrix:
8889 - os : windows
8990
9091script :
92+ - |
93+ if [ "$TRAVIS_BRANCH" == "auto" ] || [ "$TRAVIS_BRANCH" == "try" ]; then
94+ pr=$(echo $TRAVIS_COMMIT_MESSAGE | grep -o "#[0-9]*" | head -1 | sed 's/^#//g')
95+ output=$(curl -H "Authorization: token $GITHUB_API_TOKEN" -s "https://api.github.com/repos/rust-lang/rust-clippy/pulls/$pr" | \
96+ python -c "import sys, json; print(json.load(sys.stdin)['body'])" | \
97+ grep "^changelog: " | \
98+ sed "s/changelog: //g")
99+ if [ -z "$output" ]; then
100+ echo "ERROR: PR body must contain 'changelog: ...'"
101+ exit 1
102+ elif [ "$output" = "none" ]; then
103+ echo "WARNING: changelog is 'none'"
104+ fi
105+ fi
91106 - |
92107 rm rust-toolchain
93108 ./setup-toolchain.sh
You can’t perform that action at this time.
0 commit comments