1.$ git config --global user.name "xxx"
2.$ git config --global user.email [email protected]
3. Go to the directory where the file you want to upload folders
$ Git init (empty folder does not work)
4.
$ git add .
5.
$ git commit -m "java2"
java2 is just from the name,
6.
$ git remote add origin https://github.com/liangxinjingmeng/44444.git
https://github.com/liangxinjingmeng/44444.git address is on github
7.
$ git push -u origin master
This step may initially be wrong:
! [rejected] master -> master (fetch first)
error: failed to push some refs to 'https://github.com/liangxinjingmeng/44444.git'
8,9 executed after an error
8.
$ git pull --rebase origin master
9.
$ git push -u origin master