git commit -m vs. git commit -am

后端 未结 2 701
不思量自难忘°
不思量自难忘° 2021-01-30 01:43

Seems easy but I just don\'t get it. I am in the root of my application.

Here is my workflow.

git add .
git commit -m \"added a new feature some files ch         


        
2条回答
  •  谎友^
    谎友^ (楼主)
    2021-01-30 01:57

    I would suggest, if you only changed one file then you might do something like this:

    git add "Your_file.txt"
    git commit -m "added a new feature in a file"
    git push heroku master
    

    Or if you changed multiple files then you could do something like this:

    git add .
    git commit -m "some files changed"
    git push heroku master
    

    Similarly, you could add and commit all the files on one line with this command:

    git commit -am "added a new feature some files changed"
    git push heroku master
    

提交回复
热议问题