4 ms·
Shouldn't git add -A be used as default instead of git add . ?
by lukasm 12y ago
Shouldn't git add -A be used as default instead of git add . ?
- olivierlacan 12y agoHmmm, I think you're right. That's less dangerous, especially when people don't really know what they're doing. I'll push an update. That said . should be specified per manpages: > If no <pathspec> is given, the current version of Git defaults to "."; in other words, update all files in the current directory and its subdirectories. This default will change in a future version of Git, hence the form without <pathspec> should not be used.
- olivierlacan 12y agoAn update to the advice is going up that will show `git add -A .` instead of `git add .` and explain: > You can also type `git add -A .` where the dot stands for the current directory, so everything in and beneath it is added. The `-A` ensures even file deletions are included.