Tips_and_Hacks/MAST_tW_PDF_Updater/FilesForUpdates/mupload.sh

45 lines
1023 B
Bash

Do_it () {
echo
echo "pushing ULB"
(cd "/Users/Henry/Documents/WACS/en_ulb";
git pull
git commit -a -m "$answer"
git push) || { echo 'Could not commit!' >&2; exit 1; }
echo
echo "pushing UDB"
(cd "/Users/Henry/Documents/WACS/en_udb";
git pull
git commit -a -m "$answer"
git push) || { echo 'Could not commit!' >&2; exit 1; }
echo
echo "pushing tW"
(cd "/Users/Henry/Documents/WACS/en_tw";
git pull
git commit -a -m "$answer"
git push) || { echo 'Could not commit!' >&2; exit 1; }
echo
echo "pushing tN"
(cd "/Users/Henry/Documents/WACS/en_tn";
git pull
git commit -a -m "$answer"
git push) || { echo 'Could not commit!' >&2; exit 1; }
echo
echo "pushing Files for Update"
(cd "/Users/Henry/Documents/WACS/Tips_and_Hacks/MAST_tW_PDF_Updater/FilesForUpdates";
git pull
git commit -a -m "$answer"
git push) || { echo 'Could not commit!' >&2; exit 1; }
}
echo
answer=$1
if [ -z "$answer" ]
then
echo "Commit message needed"
else
echo "Commit message is $answer"
Do_it
fi
echo
echo