Git: init, add all and commit with message in one single command
git
Solution
Create an alias:
git config --global alias.here '!git init . && git add . && git commit --allow-empty -m "Initialize repository"'
then use it like
git here
Note that I added the `--allow-empty` option to `git commit`, which will let this work in an empty directory as well as one with content.
Problem
How can I group these 3 commands: - `git init` - `git add .` - `git commit -m "Initialize repository"` I have this of course, but I'm looking for something shorter & more elegant if that exists: ``` me@local:~$ git init; git add .; git commit -m "Initialize repository" ```