5 ms·
The -a switch for the commit command will only add changes from all files listed in the index. "git add ." will add changed files that are in the index and thos
by gonepostal 16y ago
The -a switch for the commit command will only add changes from all files listed in the index. "git add ." will add changed files that are in the index and those that are not. So they are not redundant commands.
- pyre 16y agoHuh? They are redundant if you run them in succession. If you've just added all changes to the index, there is no need to use the -a option to commit unstaged changes to files in the index.
- iamclovin 16y agoYou're right about them being redundant if run in succession. Fixed in the post, thanks!