1. Install Git.
2. Create a Repository
mkdir Test
2. Version Library initialization
CD test/git init
3. Add the project to Git
git add-a // mark All items
4. Submit
' Test '
5. Uploading to GitHub
Git push Origin Master
The words of success appear
Counting objects:633, done.
Delta compression using up to 4 threads.
Compressing objects:100% (615/615), done.
Writing objects:100% (633/633), 44.45 MiB | 4.00 kib/s, done.
Total 633 (Delta 161), reused 0 (Delta 0)
To https://github.com/name/polyguideoa.git
! [Remote rejected] master, master (Cannot lock ref ' Refs/heads/master ': Ref Refs/heads/master is at 4CC59104FA77BBCAD9 3BBE902F4DC2198CFC23FC but expected 1994F432668C7CB0B1CF7BDF50145456A98C17C5)
To this, basically even if the submission was successful.
But the premise is.
1. First create a new repository on GitHub named Test
2.git Clone this HTTPS address
3. Then your local will appear a test file
4. Enter
CD test/
5.git add-a Upload All
6.git commit-m ' Test '
7.git Push Origin Master
I'm using it for the time being.
Git uploads code to GitHub