25 lines
478 B
Bash
25 lines
478 B
Bash
|
#!/usr/bin/env zsh
|
||
|
|
||
|
# sync hyperdrive or create a new one
|
||
|
# if [ -f './.hyper' ]; then
|
||
|
# hyp sync ./ `cat ./.hyper` # -y
|
||
|
# else
|
||
|
# echo 'Create new hyper-drive?'
|
||
|
# hyp sync ./
|
||
|
# fi
|
||
|
|
||
|
# add ssh keys
|
||
|
eval `ssh-agent -s`
|
||
|
ssh-add ~/.ssh/github
|
||
|
ssh-add ~/.ssh/source-garden
|
||
|
|
||
|
# create placeholder commit message if none provided
|
||
|
COMMIT="$1"
|
||
|
[ -z "$COMMIT" ] \
|
||
|
&& COMMIT="__ $(date '+%Y%m%d@%H%M%S')"
|
||
|
|
||
|
git commit -am "$COMMIT"
|
||
|
|
||
|
# push all branches to every mirror
|
||
|
git push --all
|