diff options
author | 2016-08-24 15:15:09 +0200 | |
---|---|---|
committer | 2016-08-24 15:16:43 +0200 | |
commit | cb30b9d3070281a0098023feedc9d3529602fe6d (patch) | |
tree | dedbca7b33e70ff7d73ad644a8eb8cac6efc27db /docs/update.sh | |
parent | a86a53fb64dd4b9e6dfa3d6a1ebd48e30f9d3efa (diff) |
Added documentation to main tree (nw)
Diffstat (limited to 'docs/update.sh')
-rw-r--r-- | docs/update.sh | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/docs/update.sh b/docs/update.sh new file mode 100644 index 00000000000..b4becc71a11 --- /dev/null +++ b/docs/update.sh @@ -0,0 +1,20 @@ +#!/bin/sh + +git fetch + +LOCAL=$(git rev-parse @) +REMOTE=$(git rev-parse @{u}) +BASE=$(git merge-base @ @{u}) + +if [ $LOCAL = $REMOTE ]; then + echo "Up-to-date" +elif [ $LOCAL = $BASE ]; then + echo "Need to pull" + git pull + make clean + make site +elif [ $REMOTE = $BASE ]; then + echo "Need to push" +else + echo "Diverged" +fi |