Skip to content

Commit

Permalink
chore(travis): update ionic-app-base on release
Browse files Browse the repository at this point in the history
  • Loading branch information
ajoslin committed May 7, 2014
1 parent ac43236 commit 46586a4
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 2 deletions.
48 changes: 48 additions & 0 deletions scripts/app-base/publish.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@

echo "#########################"
echo "# Update ionic-app-base #"
echo "#########################"

ARG_DEFS=(
"--version=(.*)"
)

function init {
PROJECT_DIR=$SCRIPT_DIR/../..
TMP_DIR=$PROJECT_DIR/tmp
BUILD_DIR=$PROJECT_DIR/dist

APPBASE_DIR=$TMP_DIR/app-base
rm -rf $APPBASE_DIR
mkdir -p $APPBASE_DIR
}

function run {
cd ../..

rm -rf $APPBASE_DIR
mkdir -p $APPBASE_DIR

echo "-- Cloning ionic-app-base..."
git clone \
https://$GH_ORG:$GH_TOKEN@github.com/$GH_ORG/ionic-app-base.git \
$APPBASE_DIR \
--depth=10

cd $APPBASE_DIR

echo "-- Updating files..."
rm -rf $APPBASE_DIR/www/lib/ionic
mkdir -p $APPBASE_DIR/www/lib/ionic

cp -Rf $BUILD_DIR/* $APPBASE_DIR/www/lib/ionic
cp -Rf $PROJECT_DIR/scss/* $APPBASE_DIR/www/lib/ionic

git add -A
git commit -am "release: update ionic to v$VERSION"
git push -q origin master

echo "-- ionic-app-base files updated to v$VERSION successfully!"
}

source $(dirname $0)/../utils.inc
3 changes: 1 addition & 2 deletions scripts/travis/ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,9 @@ function run {
VERSION_NAME=$VERSION

./scripts/site/publish.sh --action="clone"

./scripts/site/publish.sh --action="updateConfig"

./scripts/seed/publish.sh --version="$VERSION"
./scripts/app-base/publish.sh --version="$VERSION"
else
./scripts/site/publish.sh --action="clone"

Expand Down

0 comments on commit 46586a4

Please sign in to comment.