2010-05-08 13:11:16 +00:00
|
|
|
#!/usr/bin/env zsh
|
|
|
|
|
2010-07-06 22:26:11 +00:00
|
|
|
source ~/.zshrc
|
|
|
|
|
2010-05-08 13:11:16 +00:00
|
|
|
publishdir="$HOME/Sites/blog"
|
|
|
|
publisherhost="YiMac.local"
|
|
|
|
|
|
|
|
if [[ $HOST != "YiMac.local" ]]; then
|
|
|
|
print -- "You're Not on '$publisherhost' host"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
if [[ ! -d $publishdir ]]; then
|
|
|
|
print -- "Directory '$publishdir' not found"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
# actions are:
|
|
|
|
# go to the directory containing the webroot project
|
|
|
|
# pull updates from webroot
|
|
|
|
# regen all website
|
|
|
|
# publish to mobile me
|
2010-06-17 16:11:55 +00:00
|
|
|
cd $publishdir && git pull && touch layouts/default.html && ./tasks/recompile && ./tasks/publish
|