Skip to content

Commit 54c8c23

Browse files
author
Benjamin Kampmann
committed
Add Post-Success script to build clippy-service
1 parent 94f10ee commit 54c8c23

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

.travis.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,25 @@ script:
1010

1111
# only test regex_macros if it compiles
1212
- if [[ "$(cargo build --features 'debugging test-regex_macros')" = 101 ]]; then cargo test --features 'debugging test-regex_macros'; fi
13+
14+
# trigger rebuild of the clippy-service
15+
after_success:
16+
- |
17+
#!/bin/bash
18+
set -e
19+
if [ "$TRAVIS_PULL_REQUEST" == "false" ] &&
20+
[ "$TRAVIS_REPO_SLUG" == "Manishearth/rust-clippy" ] &&
21+
[ "$TRAVIS_BRANCH" == "master" ] &&
22+
[ "$TRAVIS_TOKEN_CLIPPY_SERVICE" != "" ] ; then
23+
24+
curl -s -X POST \
25+
-H "Content-Type: application/json" \
26+
-H "Accept: application/json" \
27+
-H "Travis-API-Version: 3" \
28+
-H "Authorization: token $TRAVIS_TOKEN_CLIPPY_SERVICE" \
29+
-d "{ \"request\": { \"branch\":\"master\" }}" \
30+
https://api.travis-ci.org/repo/ligthyear%2Fclippy-service/requests
31+
32+
else
33+
echo "Ignored"
34+
fi

0 commit comments

Comments
 (0)