How to add multiple files to Git at the same time

后端 未结 10 628
半阙折子戏
半阙折子戏 2021-01-29 18:12

This will be my first git use. I have added new files ( a lot ) to the folder/project ( git local repository).

I went through online tutorials and forums and see i can do

10条回答
  •  迷失自我
    2021-01-29 18:30

    To add all the changes you've made:

    git add .

    To commit them:

    git commit -m "MY MESSAGE HERE" #-m is the message flag

    You can put those steps together like this:

    git commit -a -m "MY MESSAGE HERE"

    To push your committed changes from your local repository to your remote repository:

    git push origin master

    You might have to type in your username/password for github after this. Here's a good primer on using git. A bit old, but it covers what's going on really well.

提交回复
热议问题