8000 tools: Always upload to Rosie from Travis. (#200) · russbot/circuitpython@774bf0c · GitHub
[go: up one dir, main page]

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 774bf0c

Browse files
authored
tools: Always upload to Rosie from Travis. (adafruit#200)
This allows Rosie to automatically work for commits to forks.
1 parent 74cfdeb commit 774bf0c

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

.rosie.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ binaries:
66
bucket: adafruit-circuit-python
77
file_pattern: bin/{board}/adafruit-circuitpython-{board}-*-{short_sha}.{extension}
88
rosie_upload:
9-
file_pattern: adafruit-circuitpython-{board}-{short_sha}.{extension}
9+
file_pattern: adafruit-circuitpython-{board}*{short_sha}.{extension}
1010

1111
circuitpython_tests:
1212
test_directories:

tools/build_adafruit_bins.sh

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,13 @@ if [ $? -ne 0 ]; then
1818
version=`date +%Y%m%d`-`git rev-parse --short HEAD`
1919
fi
2020

21-
if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then
22-
version=`echo $TRAVIS_PULL_REQUEST_SHA | cut -c1-7`
21+
22+
if [ "$TRAVIS" == "true" ]; then
23+
sha=$TRAVIS_COMMIT
24+
if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then
25+
version=`date +%Y%m%d`-`echo $TRAVIS_PULL_REQUEST_SHA | cut -c1-7`
26+
sha=$TRAVIS_PULL_REQUEST_SHA
27+
fi
2328
fi
2429

2530
for board in $ATMEL_BOARDS; do
@@ -29,10 +34,10 @@ for board in $ATMEL_BOARDS; do
2934
cp atmel-samd/build-$board/firmware.uf2 bin/$board/adafruit-circuitpython-$board-$version.uf2
3035
(( exit_status = exit_status || $? ))
3136
# Only upload to Rosie if its a pull request.
32-
if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then
37+
if [ "$TRAVIS" == "true" ]; then
3338
for rosie in $ROSIE_SETUPS; do
34-
echo "Uploading to https://$rosie.ngrok.io/upload/$TRAVIS_PULL_REQUEST_SHA"
35-
curl -F "file=@bin/$board/adafruit-circuitpython-$board-$version.uf2" https://$rosie.ngrok.io/upload/$TRAVIS_PULL_REQUEST_SHA
39+
echo "Uploading to https://$rosie.ngrok.io/upload/$sha"
40+
curl -F "file=@bin/$board/adafruit-circuitpython-$board-$version.uf2" https://$rosie.ngrok.io/upload/$sha
3641
done
3742
fi
3843
done

0 commit comments

Comments
 (0)
0