update 22
This commit is contained in:
parent
4a43ab40b0
commit
8f7e2d1e2d
1 changed files with 2 additions and 10 deletions
12
autoupdate
12
autoupdate
|
@ -1,13 +1,11 @@
|
||||||
#!/usr/bin/env zsh
|
#!/usr/bin/env zsh
|
||||||
set -e
|
set -e
|
||||||
alias db="dropbox_uploader"
|
|
||||||
|
|
||||||
rm -r lib
|
rm -r lib
|
||||||
db -q download py/lib >/dev/null
|
dropbox_uploader -q download py/lib >/dev/null
|
||||||
|
|
||||||
if [ ! -d .git ]; then
|
if [ ! -d .git ]; then
|
||||||
git -q init
|
git -q init
|
||||||
[ -e version ] && rm version
|
|
||||||
git add .gitignore '*' '**/*'
|
git add .gitignore '*' '**/*'
|
||||||
else
|
else
|
||||||
git add -A
|
git add -A
|
||||||
|
@ -15,14 +13,8 @@ else
|
||||||
[ "$changes" -eq 0 ] && exit 0
|
[ "$changes" -eq 0 ] && exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -s version ]; then
|
version="$(git log --oneline | wc -l)"
|
||||||
read -r version < version
|
|
||||||
else
|
|
||||||
version=0
|
|
||||||
fi
|
|
||||||
|
|
||||||
let version++ || true # -e mode doesn't like this normally
|
let version++ || true # -e mode doesn't like this normally
|
||||||
echo $version > version
|
|
||||||
|
|
||||||
git commit -qm "update $version" . >/dev/null
|
git commit -qm "update $version" . >/dev/null
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue