aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoel Spilker <r.spilker@gmail.com>2009-07-17 23:21:56 +0200
committerRoel Spilker <r.spilker@gmail.com>2009-07-17 23:21:56 +0200
commitd7e5b5ec50104cf3ced4f282ba26539d81001986 (patch)
tree65b48cb5d74fc8732eb225c4faf0115d44d6f5ea
parent17d02d3ccace652353d75ee0ad9b5614cfa068b2 (diff)
downloadlombok-d7e5b5ec50104cf3ced4f282ba26539d81001986.tar.gz
lombok-d7e5b5ec50104cf3ced4f282ba26539d81001986.tar.bz2
lombok-d7e5b5ec50104cf3ced4f282ba26539d81001986.zip
Added useful error message in case you don't have the gh-pages branch locally.
-rwxr-xr-xwebsite/publish11
1 files changed, 9 insertions, 2 deletions
diff --git a/website/publish b/website/publish
index d97fd22d..1d8f1551 100755
--- a/website/publish
+++ b/website/publish
@@ -16,10 +16,17 @@ mkdir -p build/temp || exit
cd build/temp || exit
git clone -l -n ../.. websitegit || exit
cd websitegit || exit
-git branch gh-pages origin/gh-pages || exit
+BRANCHOK="foo"
+git branch gh-pages origin/gh-pages || BRANCHOK="bar"
+if [ $BRANCHOK == "bar" ]; then
+echo If you get error fatal: Not a valid object name: origin/gh-pages.
+echo then run: git branch gh-pages origin/gh-pages
+echo first before running this script
+ exit
+fi
git checkout gh-pages || exit
rm -r * || exit
-unzip ../../../dist/website.zip || exit
+tar xf ../../../dist/website.tar || exit
git add . || exit
git commit -a -m website || exit
git push origin gh-pages || exit