Travis-CI: Use environment variables so others can maintain nightly builds.
This commit is contained in:
@ -1,10 +1,9 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
REPO=greatscottgadgets/hackrf-nightly
|
|
||||||
PUBLICATION_BRANCH=master
|
PUBLICATION_BRANCH=master
|
||||||
# set -x
|
# set -x
|
||||||
cd $HOME
|
cd $HOME
|
||||||
# Checkout the branch
|
# Checkout the branch
|
||||||
git clone --branch=$PUBLICATION_BRANCH https://${GITHUB_TOKEN}@github.com/$REPO.git publish
|
git clone --branch=$PUBLICATION_BRANCH https://${GITHUB_TOKEN}@github.com/${REPO}.git publish
|
||||||
cd publish
|
cd publish
|
||||||
# Update pages
|
# Update pages
|
||||||
cp $ARTEFACT_BASE/$BUILD_NAME.tar.xz .
|
cp $ARTEFACT_BASE/$BUILD_NAME.tar.xz .
|
||||||
@ -22,13 +21,11 @@ echo "
|
|||||||
<h2>HackRF Nightly Builds</h2>
|
<h2>HackRF Nightly Builds</h2>
|
||||||
" > index.html
|
" > index.html
|
||||||
|
|
||||||
URL=https://greatscottgadgets.github.io/hackrf-nightly
|
|
||||||
|
|
||||||
for commit in $COMMITS; do
|
for commit in $COMMITS; do
|
||||||
FILENAME=`find . -maxdepth 1 -name "*-$commit.tar.xz"`
|
FILENAME=`find . -maxdepth 1 -name "*-$commit.tar.xz"`
|
||||||
if [ "$FILENAME" != "" ]; then
|
if [ "$FILENAME" != "" ]; then
|
||||||
FN=${FILENAME:2}
|
FN=${FILENAME:2}
|
||||||
echo "<a href=\"$URL/$FN\">$FN</a><br />" >> index.html
|
echo "<a href=\"${URL}/$FN\">$FN</a><br />" >> index.html
|
||||||
fi
|
fi
|
||||||
|
|
||||||
done
|
done
|
||||||
|
Reference in New Issue
Block a user