I\'m writing a bash script to add, commit, push all files in a directory.
#!/bin/bash
git add .
read -p \"Commit description: \" desc
git commit -m $de
Here's a merge of the last two answers - chaining together the add -u is awesome, but the embedded read command was causing me troubles. I went with (last line used for my heroku push, change to 'git push origin head' if that's your method):
#!/bin/bash
read -p "Commit description: " desc
git add . && \
git add -u && \
git commit -m "$desc" && \
git push heroku master