In in 95% of my time I type "git add . -A" directly followed by "git commit -m "message" in the Git version control system. That is a lot of typing for a very common case. Fortunately git allows to add an alias for the command. To add an alias for git add and git commit to your git configuration, open your .git/config file and add the following. [code source="shell"] [alias] ac = !git add -A && git commit [/code] Alternative you can use the --global flag from the command line: [sourcecode type="shell"] git config --global alias.ac '!git add -A && git commit' [/sourcecode] You now can add and commit to your Git repository via the command: [sourcecode type="shell"] git ac -m "message" [/sourcecode] Unfortunately alias seems not to be supported on the window implementation of git (msysgit). See the following discussion for details: msysgit does not support alias definition. I hope this helps. More details can be found in my Git Tutorial. You may More
git
2010-12-25