ubuntu githib 上传项目
2017-12-17 17:59
148 查看
Ubuntu githib 上传项目
一.安装githib
sudo apt-get install git git-core git-gui git-doc git-svn git-cvs gitweb gitk git-email git-daemon-run git-el git-arch
二.安装ssh keys
cd ~/.ssh
ssh-keygen -t rsa -C “你自己的github对应的邮箱地址”
文件名:id_rsa(私钥) 同时公钥id_rsa.pub 一起被创建
在GitHub中,依次点击Settings -> SSH Keys -> Add SSH Key,将id_rsa.pub文件中的字符串复制进去,注意字符串中没有换行和空格。
ssh -T git@github.com 查看是否连接成功
三.开始使用
配置git:
git config –global user.name “你的github用户名”
git config –global user.email “你的github邮箱地址”
上传项目:
进入项目目录 cd xxx(xxx为你想上传的项目目录)
git init
git commit -m + “yourproject”
Push:git remote add origin https://github.com/你的github用户名/你的github仓库.git
如果:fatal: 远程 origin 已经存在。
git remote rm origin
输入用户名和密码即可
git push origin master
相关文章推荐
- 如何用命令将本地项目上传到git
- 码云git使用一(上传本地项目到码云git服务器上)
- 如何使用Git上传项目代码到github
- AndroidStudio-Git-本地项目添加Git并初次上传到远程Git
- git命令上传本地项目至GitHub
- AndroidStudio中使用Git-初级篇(一)——从github上传和下载项目(by 星空武哥)
- Git 上传文件、文件夹或项目到 Github
- 【转载】使用git将本地项目上传到github
- Git——新手入门与上传项目到远程仓库GitHub
- Eclipse上传/下载Git项目
- Git的使用--将本地项目上传至github
- IDEA上传项目至git
- windows下基于gitbash上传项目到github
- git向github上传完整项目
- 怎么上传项目到Git
- 如果用命令将本地项目上传至git
- 在ubuntu上通过git上传到源代码到github网站上
- 如何使用Git上传项目代码到github
- win7 git上传本地项目至github