0

I have a ton of Repos (20+) that I am just starting out on. I know this is not good practice in general, but I am the only developer so far, and I want to make sure I check in everything before I go to bed, compilable or not just to save it. No one else is using it now, so this is a temporary solution. I have this script I wrote:

cd /asdf/code/My-Parent
git add *
git commit
git push
cd ../My-Parent-Core
git add *
git commit
git push

.... forever. However, it asks for a commit description, which I have no problem making "Nightly Check in: at first. ( I would like to stress this is just a solution to a beginning of a project.)

Is there a way to add a commit message to my "git commit" line so I can be sure that I saved everything before I go to bed?

Tiago Mussi
  • 801
  • 3
  • 13
  • 20
mmaceachran
  • 3,178
  • 7
  • 53
  • 102

1 Answers1

4

Use git commit -m "your message here" to add a commit message at the time of committing.

However, your method of using git add * won't take into account any files you've deleted. You can either also run git add -u or do both new and existing files using git add -A. A nice answer on that can be found here.

LeonardChallis
  • 7,759
  • 6
  • 45
  • 76