GitHub can also be used as a place for file sharing, but the free space is only 300 MB, so files cannot be enlarged. Otherwise, they can become a download site for sharing resources, which is very convenient.Common commands:
Git Add. // Add all files to the index
Git commit // submit to the local source code library, and the default VI editor will be opened to write "Comments"
Git remote add origin [email protected]: viprs/Hello-World.git // Add remote target as origin
Git push origin master // push the local source code library to GitHub
Git pull origin master // pullLocal source code libraryNote: (GIT commit-m'remove aa.txt'
-
Never use-a to force all
Submit
A project occupies 150 MB/300 mb after being submitted several times.) Example: create a"
Projclean"Project, the following are the specific operation steps. Global setup:
Set up git tell GitHub Who You Are git config -- global user. Name "viprs" Git config -- global user. Email [email protected]
Next steps:
mkdir ProjClean cd ProjClean git init touch README git add README git commit -m ‘first commit‘ git remote add origin https://github.com/viprs/ProjClean.git git push -u origin master
Existing git Repo?
CD existing_git_repo git remote add origin https://github.com/viprs/ProjClean.git git push-u origin master //-U is the prompt user name, password
Importing a subversion Repo?
Check out the guide for step by step instructions.
When you're done:
Continue