Nan Xiao
Nan Xiao

Reputation: 17467

Is "git add" the only operation to bring the file into staging area?

enter image description here

I am a newbie of git. After studying for a while, I have the following doubt: Is git add the only operation to bring the file into staging area while git commit the only operation to bring the file into revision history? If not, is there any other commands can achieve it?

Upvotes: 1

Views: 125

Answers (1)

user764357
user764357

Reputation:

No, you can also use git commit -a to add all previously added files into staging and then commit them in one go.

For example:

git commit -am "updated CSS"

Upvotes: 1

Related Questions