美文网首页
How to create a repo from remote

How to create a repo from remote

作者: 易燃易爆品 | 来源:发表于2015-01-28 22:28 被阅读0次

How to create a repo from remote

There are few steps we should take to create a new repo and make progress:


step 1. Use github API to create a new repo:

curl -u 'USER' https://api.github.com/user/repos -d '{"name":"PROJECT_NAME", "description":"THIS IS A PROJECT."}'


step 2. Git init to initialize the local project files.

git init

git remote add origin THE_REPO_URI

THE_REPO_URIcan be one of following two forms:

ssh form: git@github.com:USER/projectname.git

https form: https://github.com/USER/projectname.git


step 3. First commit:

git add .

git commit -a 'first commit.'


step 4. First push.

git push --set-upstream origin master


Done.

Be productive and make project progress!

相关文章

网友评论

      本文标题:How to create a repo from remote

      本文链接:https://www.haomeiwen.com/subject/qwbkxttx.html