ubuntu_git下远程提交代码
来源:互联网 发布:软件著作权模板 编辑:程序博客网 时间:2024/06/01 10:16
在終端輸入:
git init初始化git
不然會報以下錯誤:
xyxt@xyxt-System-Product-Name:~/Downloads$ sudo git config user.name "wugaosheng"[sudo] password for xyxt: fatal: not in a git directory
3.设置用户名和邮箱:
设置用户名: sudo git config user.name "jellyCai"
设置用户邮箱:sudo git config user.email "18617050557@163.com"
生成秘钥
ssh-keygen -t rsa -C "youaccount@gmail.com"
然后再运行:
cd ~/.ssh
再运行:
sudo gedit id_rsa.pub
把里面的密钥添加到github账户上的setting->SSH keys里面
提交代码至GitHub:
首先,在github.com上创建一个新的repo,根据情况加上适当的.gitignore,LICENSE等,然后提交本地代码至github
git clone yourrepository
git pull #获取新版本git status #获取需要上传的文件 git add . # .表示全添加, git add README.md 表示只添加说明文件git commit -m "add new files" # a commitgit push -u origin master
参考文献:
[1].ubuntu 下安装git 并上传代码至github
阅读全文
0 0
- ubuntu_git下远程提交代码
- 远程提交代码
- git提交远程代码库
- Git远程服务器提交代码
- windows下使用GUI 把本地代码提交到git远程仓库
- windows下使用GUI 把本地代码提交到git远程仓库
- windows下使用GUI 把本地代码提交到git远程仓库
- git提交代码至远程仓库
- ios提交代码到远程仓库
- git命令行提交代码到远程仓库
- egit提交代码到远程仓库
- 使用git提交代码到远程服务器
- GIT提交代码到远程创库
- git提交工程代码到远程库
- Git代码提交到CSDN远程仓库
- eget无法提交代码到远程仓库
- ubuntu提交代码到远程仓库
- git提交代码到远程服务器
- PicPick的安装方法
- promise then catch
- 异步fifo的设计(一)
- 从零单排_JAVA 青铜4(构造器,初始化块)
- java学习笔记
- ubuntu_git下远程提交代码
- Jenkins安装配置
- 串口M1卡读写模块,串口Mifare 读写模块,串口Ntag213/215/216读写模块
- 把符合日期格式的字符串解析成日期
- 单点登录原理与简单实现
- AndroidStudio 相同jar包配置文件冲突(DuplicateFileException)
- 用R语言DIY机器学习算法--Kmeans
- 1003. 我要通过!(20)
- grub过程