Skip to content

Instantly share code, notes, and snippets.

@pyxn
Last active May 12, 2020 19:53
Show Gist options
  • Save pyxn/d310554d135d76cf7b05169a240cbe4a to your computer and use it in GitHub Desktop.
Save pyxn/d310554d135d76cf7b05169a240cbe4a to your computer and use it in GitHub Desktop.
Shell Script: Git Push Sequence
echo "Initialize $0 script..."
git add .
git commit -m "$1"
git push -u origin master
git log --oneline
echo "$0 successful."
echo "--------------------------------"
# --------------------------------
# Usage on MacOS
# --------------------------------
# Save as deploy.sh on your project folder with git repository initialized
#
# Enter on terminal to make script executable >> chmod +x deploy.sh
# Enter on terminal to execute the .sh script >> ./deploy.sh "your commit message here"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment