Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否有git commit -a用于暂存新文件的等价物?
git commit -a
这是 的行为git add -A,但前提是您从存储库的根目录调用它。否则,它只会在子目录中添加文件。
git add -A
还是不存在这样的内置功能,使最简单的程序可以编写类似的东西git add -A $(git rev-parse --show-toplevel)?
git add -A $(git rev-parse --show-toplevel)
您可以使用 git 的内置aliasses,其中包括调用 shell 脚本的能力。