Skip to content

Commit

Permalink
Support for passing in the branch via a command line parameter,
Browse files Browse the repository at this point in the history
defaulting to “master”.
  • Loading branch information
jeffposnick committed May 27, 2014
1 parent a5a182e commit 2d43f41
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion bin/gp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
# Run in a clean directory passing in a GitHub org and repo name
org=$1
repo=$2
branch=$3
: ${branch:="master"}

# make folder (same as input, no checking!)
mkdir $repo
Expand All @@ -21,7 +23,7 @@ git rm -rf -q .

# use bower to install runtime deployment
bower cache clean $repo # ensure we're getting the latest from master.
bower install --config.directory="components" $org/$repo#master
bower install --config.directory="components" $org/$repo#$branch

# redirect by default to the component folder
echo "<META http-equiv="refresh" content=\"0;URL=components/$repo/\">" >index.html
Expand Down

0 comments on commit 2d43f41

Please sign in to comment.