在远程ubuntu安装git

连接远程服务器

可以通过pycharm,vscode,SecureCRT等工具配置连接远程服务器

  1. pycharm远程连接服务器完整教程
  2. Windows下如何使用VScode连接远程linux服务器进行远程开发
  3. SecureCRT安装全部教程(步骤详细)
  4. SecureCRT的使用教程

使用apt命令安装git

Git 软件包被包含在 Ubuntu 默认的软件源仓库中,并且可以使用 apt 包管理工具安装。这是在 Ubuntu 上安装 Git 最便利,最简单的方式。

1.以 sudo 权限用户身份运行下面的命令:

sudo apt update
# 更新apt工具

显示以下信息,这个更新因情况而定

获取:1 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal InRelease [265 kB]
获取:2 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
命中:3 http://cn.archive.ubuntu.com/ubuntu focal InRelease
获取:4 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates InRelease [114 kB]
获取:5 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports InRelease [108 kB]
获取:6 http://cn.archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
获取:7 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security InRelease [114 kB]
获取:8 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main i386 Packages [718 kB]
获取:9 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main amd64 Packages [970 kB]
获取:10 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main Translation-en [506 kB]
获取:11 http://cn.archive.ubuntu.com/ubuntu focal-backports InRelease [108 kB]
获取:12 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main Translation-zh_CN [113 kB]
0% [12 Translation-zh_CN store 0 B] [11 InRelease 28.0 kB/108 kB 26%] [正在     获取:13 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main amd64 DEP-11 Metadata [494 kB]
0% [11 InRelease 28.0 kB/108 kB 26%] [13 Components-amd64 16.1 kB/494 kB 3%] [  获取:14 http://security.ubuntu.com/ubuntu focal-security/universe amd64 DEP-11 Metadata [66.4 kB]
获取:15 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main DEP-11 48x48 Icons [98.4 kB]
获取:16 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main DEP-11 64x64 Icons [163 kB]
获取:17 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main DEP-11 64x64@2 Icons [15.8 kB]
获取:18 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main amd64 c-n-f Metadata [29.5 kB]
获取:19 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/restricted amd64 Packages [22.0 kB]
0% [15 icons-48x48 store 0 B] [11 InRelease 34.5 kB/108 kB 32%] [正在等待% [11 I0% [16 icons-64x64 store 0 B] [11 InRelease 34.5 kB/108 kB 32%] [正在等待       获取:20 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/restricted i386 Packages [8,112 B]
获取:21 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/restricted Translation-en [6,212 B]
获取:22 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/restricted Translation-zh_CN [1,324 B]
获取:23 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/restricted amd64 c-n-f Metadata [392 B]
获取:24 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe i386 Packages [4,642 kB]
获取:25 http://cn.archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [920 kB]
23% [25 Packages 4,943 B/920 kB 1%] [24 Packages 999 kB/4,642 kB 22%] [正在     获取:26 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 DEP-11 Metadata [2,464 B]
获取:27 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe amd64 Packages [8,628 kB]
获取:28 http://cn.archive.ubuntu.com/ubuntu focal-updates/universe i386 Packages [679 kB]
获取:29 http://cn.archive.ubuntu.com/ubuntu focal-updates/universe amd64 DEP-11 Metadata [390 kB]
获取:30 http://cn.archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 DEP-11 Metadata [944 B]
获取:31 http://cn.archive.ubuntu.com/ubuntu focal-backports/universe amd64 DEP-11 Metadata [30.7 kB]
获取:32 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe Translation-en [5,124 kB]
获取:33 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe Translation-zh_CN [388 kB]
获取:34 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe amd64 DEP-11 Metadata [3,603 kB]
获取:35 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe DEP-11 48x48 Icons [3,016 kB]
获取:36 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe DEP-11 64x64 Icons [7,794 kB]
获取:37 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe DEP-11 64x64@2 Icons [44.3 kB]
获取:38 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe amd64 c-n-f Metadata [265 kB]
获取:39 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse i386 Packages [74.7 kB]
获取:40 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse amd64 Packages [144 kB]
获取:41 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse Translation-zh_CN [4,612 B]
获取:42 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse Translation-en [104 kB]
获取:43 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse amd64 DEP-11 Metadata [48.4 kB]
获取:44 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse DEP-11 48x48 Icons [23.1 kB]
获取:45 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse DEP-11 64x64 Icons [192 kB]
获取:46 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse DEP-11 64x64@2 Icons [214 B]
获取:47 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse amd64 c-n-f Metadata [9,136 B]
获取:48 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main amd64 Packages [1,750 kB]
获取:49 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main i386 Packages [637 kB]
获取:50 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main Translation-en [326 kB]
获取:51 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main amd64 DEP-11 Metadata [278 kB]
获取:52 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main DEP-11 48x48 Icons [60.8 kB]
获取:53 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main DEP-11 64x64 Icons [98.3 kB]
获取:54 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main DEP-11 64x64@2 Icons [29 B]
获取:55 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main amd64 c-n-f Metadata [15.0 kB]
获取:56 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/restricted i386 Packages [24.3 kB]
获取:57 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/restricted amd64 Packages [947 kB]
获取:58 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/restricted Translation-en [135 kB]
获取:59 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/restricted amd64 c-n-f Metadata [528 B]
获取:60 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe i386 Packages [679 kB]
获取:61 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe amd64 Packages [920 kB]
获取:62 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe Translation-en [206 kB]
获取:63 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe amd64 DEP-11 Metadata [391 kB]
获取:64 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe DEP-11 48x48 Icons [257 kB]
获取:65 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe DEP-11 64x64 Icons [458 kB]
获取:66 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe DEP-11 64x64@2 Icons [29 B]
获取:67 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe amd64 c-n-f Metadata [20.7 kB]
获取:68 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse amd64 Packages [24.4 kB]
获取:69 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse i386 Packages [8,432 B]
获取:70 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse Translation-en [7,336 B]
获取:71 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse amd64 DEP-11 Metadata [944 B]
获取:72 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse DEP-11 48x48 Icons [1,867 B]
获取:73 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse DEP-11 64x64 Icons [2,497 B]
获取:74 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse DEP-11 64x64@2 Icons [29 B]
获取:75 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse amd64 c-n-f Metadata [592 B]
获取:76 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main i386 Packages [34.8 kB]
获取:77 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main amd64 Packages [42.2 kB]
获取:78 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main Translation-en [10.1 kB]
获取:79 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main amd64 DEP-11 Metadata [9,576 B]
获取:80 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main DEP-11 48x48 Icons [6,961 B]
获取:81 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main DEP-11 64x64 Icons [10.5 kB]
获取:82 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main DEP-11 64x64@2 Icons [29 B]
获取:83 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main amd64 c-n-f Metadata [864 B]
获取:84 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/restricted amd64 c-n-f Metadata [116 B]
获取:85 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe amd64 Packages [22.7 kB]
获取:86 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe i386 Packages [12.8 kB]
获取:87 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe Translation-en [15.5 kB]
获取:88 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe amd64 DEP-11 Metadata [30.8 kB]
获取:89 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe DEP-11 48x48 Icons [13.2 kB]
获取:90 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe DEP-11 64x64 Icons [22.6 kB]
获取:91 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe DEP-11 64x64@2 Icons [29 B]
获取:92 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe amd64 c-n-f Metadata [804 B]
获取:93 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/multiverse amd64 c-n-f Metadata [116 B]
获取:94 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/main i386 Packages [428 kB]
获取:95 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/main amd64 Packages [1,422 kB]
获取:96 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/main Translation-en [246 kB]
获取:97 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/main amd64 DEP-11 Metadata [40.7 kB]
获取:98 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/main DEP-11 48x48 Icons [18.3 kB]
获取:99 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/main DEP-11 64x64 Icons [35.5 kB]
获取:100 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/main DEP-11 64x64@2 Icons [29 B]
获取:101 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/main amd64 c-n-f Metadata [10.1 kB]
获取:102 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/restricted amd64 Packages [886 kB]
获取:103 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/restricted i386 Packages [22.0 kB]
获取:104 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/restricted Translation-en [126 kB]
获取:105 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/restricted amd64 c-n-f Metadata [532 B]
获取:106 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe i386 Packages [550 kB]
获取:106 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe i386 Packages [550 kB]
获取:107 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe amd64 Packages [702 kB]
获取:108 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe Translation-en [125 kB]
获取:109 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe amd64 DEP-11 Metadata [66.6 kB]
获取:110 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe DEP-11 48x48 Icons [33.1 kB]
获取:111 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe DEP-11 64x64 Icons [71.6 kB]
获取:112 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe DEP-11 64x64@2 Icons [29 B]
获取:113 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/universe amd64 c-n-f Metadata [14.4 kB]
获取:114 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/multiverse amd64 Packages [20.7 kB]
获取:115 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/multiverse i386 Packages [7,180 B]
获取:116 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/multiverse Translation-en [5,196 B]
获取:117 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/multiverse amd64 DEP-11 Metadata [2,464 B]
获取:118 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/multiverse DEP-11 48x48 Icons [29 B]
获取:119 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/multiverse DEP-11 64x64 Icons [2,638 B]
获取:120 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/multiverse DEP-11 64x64@2 Icons [29 B]
获取:121 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security/multiverse amd64 c-n-f Metadata [500 B]
已下载 52.5 MB,耗时 15秒 (3,510 kB/s)
正在读取软件包列表... 完成
sudo apt install git
# git安装git命令

显示如下

正在读取软件包列表... 完成
正在分析软件包的依赖关系树
正在读取状态信息... 完成
下列软件包是自动安装的并且现在不需要了:accountsservice-ubuntu-schemas gnome-screensaver indicator-bluetoothindicator-sound jayatana libaccounts-glib0 libbamf3-2 libfwupdplugin1libgnome-panel0 libido3-0.1-0 liblightdm-gobject-1-0 libunity-gtk2-parser0libunity-gtk3-parser0 libunity-settings-daemon1 liburl-dispatcher1ubuntu-touch-sounds unity-gtk-module-common unity-gtk2-moduleunity-gtk3-module unity-settings-daemon-schemas
使用'sudo apt autoremove'来卸载它(它们)。
将会同时安装下列软件:git-man liberror-perl
建议安装:git-daemon-run | git-daemon-sysvinit git-doc git-el git-email git-gui gitkgitweb git-cvs git-mediawiki git-svn
下列【新】软件包将被安装:git git-man liberror-perl
升级了 0 个软件包,新安装了 3 个软件包,要卸载 0 个软件包,有 83 个软件包未被升级。
需要下载 5,471 kB 的归档。
解压缩后会消耗 38.4 MB 的额外空间。
您希望继续执行吗? [Y/n] y
获取:1 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main amd64 liberror-perl all 0.17029-1 [26.5 kB]
获取:2 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main amd64 git-man all 1:2.25.1-1ubuntu3.4 [885 kB]
获取:3 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main amd64 git amd64 1:2.25.1-1ubuntu3.4 [4,560 kB]
已下载 5,471 kB,耗时 1秒 (3,661 kB/s)
正在选中未选择的软件包 liberror-perl。
(正在读取数据库 ... 系统当前共安装有 195272 个文件和目录。)
准备解压 .../liberror-perl_0.17029-1_all.deb  ...
正在解压 liberror-perl (0.17029-1) ...
正在选中未选择的软件包 git-man。
准备解压 .../git-man_1%3a2.25.1-1ubuntu3.4_all.deb  ...
正在解压 git-man (1:2.25.1-1ubuntu3.4) ...
正在选中未选择的软件包 git。
准备解压 .../git_1%3a2.25.1-1ubuntu3.4_amd64.deb  ...
正在解压 git (1:2.25.1-1ubuntu3.4) ...
正在设置 liberror-perl (0.17029-1) ...
正在设置 git-man (1:2.25.1-1ubuntu3.4) ...
正在设置 git (1:2.25.1-1ubuntu3.4) ...
正在处理用于 man-db (2.9.1-1) 的触发器 ...

2.查看git版本,验证是否安装成功

git --version

显示如下

git version 2.25.1

到此安装成功

git基本使用

配置git

  1. git初始化
git init

此时,会看见根目录目录下会有.git文件夹

  1. 初始关联github账号和邮箱
git config --global username "Your github username"
# "Your github Name" 中填写你的github账号用户名
git config --global user.email "yourgitemail@yourdomain.com"
# "yourgitemail@yourdomain.com" 中填写你github注册的邮箱
  1. 验证git配置是否成功
git config --list

输出显示格式如下

user.name=Your github username
user.email=yourgitemail@yourdomain.com

配置文件被存储在~/.gitconfig文件:
可使用命令 sudo cat ~/.gitconfig查看
内容显示如下

[user]name = Your github usernameemail = yourgitemail@yourdomain.com

后续也可以通过vim ~/.gitconfig命令进行配置修改
Linux系统Ubuntu终端用命令编辑一文件并保存

git克隆远程仓库至本地

  1. 按上面步骤完成git配置
  2. 将你的电脑和github账号通过SSHkey绑定,输入以下命令
cd ~/.ssh
# 如果输入命令后无法进入,则说明还没有在本地机器上绑定你自己github账户的公钥
  • 然后使用ls命令查看ssh文件夹下有没有id_rsa、id_rsa.pub这两个文件,如果没有那么就需要绑定ssh key,输入以下命令进行绑定
ssh-keygen -t rsa -C "your github username"
  • 然后一直按Enter回车,会出现以下信息,最终在.ssh目录就会生成两个文件,即id_rsa、id_rsa.pub
Generating public/private rsa key pair.
Enter file in which to save the key (/home/boss_wong/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/username/.ssh/id_rsa
Your public key has been saved in /home/username/.ssh/id_rsa.pub
The key fingerprint is:
XXX
The key's randomart image is:
XXX
  • 可以再通过ls命令验证是否生成id_rsa、id_rsa.pub这两个文件

  • 下一步输入命令cat id_rsa.pub查看公钥信息,然后复制里边的信息,在网页登录github账号,点击个人头像,进入setting,然后选择SSH and GPG key,在SSH keys点击New SSH key,然后将复制的信息粘贴进去保存。

  • 添加成功之后,在git里输入命令:ssh git@github.com,验证是否连接成功。如果提示You've successfully authenticated就成功了,那么就可以把自己github远程仓库的代码clone到本地了。

  1. clone别人项目到服务器
  • 首先需要fork别人的项目到自己的github仓库
  • 然后输入以下ssh克隆命令进行克隆项目至服务器,可以自己选择存放路径
git clone githubrepository
# 其中githubrepository的格式为git@github.com:username/repository_name

以下为地址

  • 出现如下类似信息则表明clone命令成功
正克隆到 'XXX'
remote: Enumerating objects: 75, done.
remote: Counting objects: 100% (75/75), done.
remote: Compressing objects: 100% (64/64), done.
接收对象中:  18% (14/75), 4.09 MiB | 24.00 KiB/s/s

参考资料

【1】如何在 Ubuntu 20.04 上安装 Git
【2】如何使用git在本地电脑clone别人的github上的远程仓库代码

【Ubuntu安装git与git clone远程仓库】相关推荐

  1. 【Eclipse中使用Git之一】把远程仓库的项目,clone到eclipse里面

    [Eclipse中使用Git之一]把远程仓库的项目,clone到eclipse里面 2015-01-29 19:25 15779人阅读 评论(1) 收藏 举报 分类: Git(35) 作者同类文章X ...

  2. 从命令行到IDE,版本管理工具Git详解(远程仓库创建+命令行讲解+IDEA集成使用)

    首先,Git已经并不只是GitHub,而是所有基于Git的平台,只要在你的电脑上面下载了Git,你就可以通过Git去管理"基于Git的平台"上的代码,常用的平台有GitHub.Gi ...

  3. Git的使用——Git 常用命令总结、Git的使用、Git 的分支、远程仓库的使用、IDEA 中使用Git、Git 工作流(Git Flow、Github Flow、GitLab Flow)

    Git的使用--Git 常用命令总结.Git的使用.Git 的分支.远程仓库的使用.IDEA 中使用Git 一.Git 常用命令总结 为了方便后续查找命令,故先把总结放前面,教程放后面 1.git 基 ...

  4. Git 之五 通信协议(HTTPS、SSH、Git)、使用远程仓库(GitHub、GitLab、Gitee等)

    写在前面   Git 的官网上有很详细的使用教程(当然有翻译版本),具体地址是 https://git-scm.com/book/zh/v2.唯一不足就是,很多讲解并没有实机演示.但是,毫无疑问,官网 ...

  5. Git HTTP方式克隆远程仓库到本地

    操作步骤 Git 通过HTTP方式克隆远程仓库到本地总共需要三步: 登录我们的github 复制我们的github 项目的https 地址. 在我们的本地磁盘下创建文件夹用来保存我们的远程git项目. ...

  6. 【Git入门之六】远程仓库

    2019独角兽企业重金招聘Python工程师标准>>> 远程仓库是用来把Git仓库托管到互联网,本地网络或者本机中. 本文主要介绍在本机中创建远程仓库(Remote reposito ...

  7. git操作:将远程仓库(主库)更新到本地,并同步到fork的个人库

    适用场景:在不能直接push或者pull主库(远程仓库)的情况下(如公司的代码库不能随意操作),需要先fork到自己的个人仓库,然后再git clone到本地. 此时需要将主库的修改更新到本地,再将自 ...

  8. git修改本地和远程仓库名称的解决方法

    git修改本地和远程仓库名称的解决方法 参考文章: (1)git修改本地和远程仓库名称的解决方法 (2)https://www.cnblogs.com/zlting/p/9620259.html 备忘 ...

  9. 如何通过git提交代码到远程仓库

    ** 如何通过git提交代码到远程仓库(github) ** 进入项目文件夹,右击鼠标键->Git Basd Here 1.初始化本地仓库 git init 2.将所有文件添加到本地仓库(也可添 ...

  10. git本地项目关联远程仓库

    git本地项目关联远程仓库 背景 实际开发中,偶尔会遇到从零开始开发一个项目的情况,常常是先在本地开发,再推送到远程仓库,记录一下从创建本地仓库开始,到推送远程仓库的过程 流程概述 远程创建项目,这一 ...

最新文章

  1. MFC中利用CFileDialog选择文件并读取文件所遇到的问题和解决方法
  2. matlab中的containers.Map()
  3. golang模板语法
  4. 周志华教授专著《集成学习:基础与算法》上市,豆瓣满分森林书破解AI实践难题...
  5. 最强动画制作人书包_声优访谈丨恋与制作人动画中配声优访谈——夏磊
  6. LeetCode刷题——无重复字符的最长子串
  7. 百家号 python高手养成_python高手养成记04:python的所有数据类型,一篇足矣
  8. 无法删除oracle用户的问题
  9. sublime配置python-rpel_SublimeREPL配置Python3开发
  10. 没钱发工资?当着董事长总经理是好玩的,不用负责?
  11. [转]教你如何在博客园放“可运行代码
  12. Crypto-js加密解密
  13. xcode打包IPA(完整详细图文)
  14. 计算机xp系统恢复以前设置,如何设置xp系统一键还原
  15. 乡土中国思维导图精华版
  16. UBI文件系统的制作与挂载案例
  17. 2021-10-26 Ubantu练习打字的小游戏
  18. Windows C盘清理
  19. raft协议对网络分区的处理
  20. 蓝牙电话协议HFP(Hands-Free Profile) SCO建立/释放/在通话中Audio transfer

热门文章

  1. 115-545-003丨Alexa Fluor 488标记亲和纯化山羊抗小鼠IgG(H+L)二抗
  2. matlab中巴特沃斯滤波器的使用
  3. Python中 list[:]与 list 的区别
  4. MATLAB线性回归实例 平炉炼钢
  5. XAMPP之Apache、MySQL不能正常启动的解决办法
  6. security基于数据库的认证(二)
  7. 玫瑰花html有颜色的,玫瑰花有哪些颜色
  8. 边缘计算,是在炒概念吗?
  9. okio篇 1.Buffer
  10. Percona 数据库