安装git工具在ubuntu系统
Git is one of the most popular tools used for distributed version control system(VCS). Git is commonly used for source code management (SCM) and has become more used than old VCS systems like SVN.
Installing Git on Ubuntu 16.04 LTS
- You should be running a server with any Ubuntu 16.04 LTS release.
- You will need to log in to SSH via the root user.
- In this tutorial I’ll be working with a Core Managed Ubuntu 16.04.4 LTS server
First, as always, we should start out by running general OS and package updates. On Ubuntu we’ll do this by running:apt-get update
After you have run the general updates on the server you can get started with installing Git.
- Install Git 【需要root权限】
apt-get install git-core
You may be asked to confirm the download and installation; simply enter y to confirm. It’s that simple, git should be installed and ready to use! - Confirm Git the installation
With the main installation done, first check to ensure the executable file is setup and accessible. The best way to do this is simply to run git with the version command.git --version【非root角色登陆查看】
git version 2.7.4
- Configure Git’s settings (for the root user)
It’s a good idea to setup your user for git now, to prevent any commit errors later. We’ll setup the user testuser with the e-mail address testuser@example.com.git config --global user.name "testuser"
git config --global user.email "testuser@example.com"Note:It’s important to know that git configs work on a user by user basis. For example if you have a ‘david’ Linux user and they will be working with git then David should run the same commands from his user account. By doing this the commits made by the ‘david’ Linux user will be done under his details in git. - Verify the Config changes
Now we’ll verify the configuration changes by viewing the .gitconfig file. You can do this a few ways, we’ll show you both methods here.- View the config file using cat with the following command:
cat ~/.gitconfig
- Or, you can also view the same details using the git config command:
git config --list
- View the config file using cat with the following command:
And that’s it! You have now installed Git on your Ubuntu 16.04 LTS server and have it configured on your root user. You can get rolling with your code changes from here, or you can repeat steps 3 and 4 for the other system user accounts.
安装git工具在ubuntu系统的更多相关文章
- SLAM+语音机器人DIY系列:(一)Linux基础——2.安装Linux发行版ubuntu系统
摘要 由于机器人SLAM.自动导航.语音交互这一系列算法都在机器人操作系统ROS中有很好的支持,所以后续的章节中都会使用ROS来组织构建代码:而ROS又是安装在Linux发行版ubuntu系统之上的, ...
- Windows 下安装Git工具及基础使用
Git简介 git是很好一个工具使用,可以执行liunx命令,有git环境后windows系统就可以进行shell命令操作,就可以添加其他liunx辅助软件进行执行,git也代码库管理工具,无论是上传 ...
- Ubuntu下安装git工具
环境:Ubuntu 9.10 git-1.8.2.3.tar.bz2 1.将安装包下载到所选文件夹下,如:/tmp 2.tar -xjf git-1.8.2.3.tar.bz2 3.cd git-1. ...
- 高显卡安装 低版本的ubuntu系统导致hdmi线不能用
- 源码安装git工具,显示/usr/local/lib64/libcrypto.a(dso_dlfcn.o) undefined reference to `dlopen'
/usr/local/lib64/libcrypto.a(dso_dlfcn.o): In function `dlfcn_globallookup':dso_dlfcn.c:(.text+0x30) ...
- CentOS_6.5 64位系统,安装git服务器+客户端
================ git服务器安装 ==================== CentOS安装Git服务器 Centos 6.4 + Git 1.8.2.2 + gitosis## . ...
- git工具的安装和使用
啰嗦几句: 世界上本没有后悔药,但软件开发提供了后悔药,那就是代码管理工具.它可以让你的代码穿越回以前的状态,甚至可以指定某一个时刻,而且还可以穿越回来. 当下流行的代码管理工具有 SVN 和 GIT ...
- Ubuntu 系统服务器初始化配置、安全加固、内核优化和常用软件安装的Shell脚本分享
转载自:https://www.bilibili.com/read/cv13875402?spm_id_from=333.999.0.0 描述: 适用于企业内部 Ubuntu 操作服务器初始化.系统安 ...
- Git工具的使用教程
Git 是一种版本控制工具,也叫作版本管理软件(分布式管理软件).这里介绍Git的基本使用步骤,关于 Git 更详细的介绍,读者可以参考其官方网站提供的文档. 1 安装Git 在Ubuntu系统中安 ...
随机推荐
- 理解 IntelliJ IDEA 的项目配置和Web部署(转载)
理解 IntelliJ IDEA 的项目配置和Web部署 1.项目配置的理解 IDEA 中最重要的各种设置项,就是这个 Project Structre 了,关乎你的项目运行,缺胳膊少腿都不行.最 ...
- Glide4 高效加载图片的配置【转】
原文: Glide4 高效加载图片的配置 https://www.jianshu.com/p/a079713f280f
- 学JS的心路历程Day28 - PixiJS -基础(二)
材质暂存(texture cache) 昨天有说到,图片要放入stage前,需要先把图片转成Sprite的特殊图片物件. 但是我们也可以先将图片放进材质暂存(texture cache). 什么是「材 ...
- opencv输出图片像素值
需求:在控制台输出灰度图像的像素值 代码: #include <stdio.h> #include <iostream> #include <opencv2/core/c ...
- ubuntu16.04获取root权限并用root用户登录
写在全面:如果根据以下教程涉及到只读文件需要更改文件权限才能需修改文件内容,参考我的另一篇博客:https://www.cnblogs.com/masbay/p/10744900.html中的第2条. ...
- ADO.Net 数据库修改
数据库的修改方法和增加一样,只是把增加语句换成了修改语句,后面执行语句是相同的 首先也是需要获取并接收输入的要修改的哪个数据以及修改后的数据 代码演示: using System; using Sys ...
- php常见排序
public function actionQuickSort(){ $arr = ['5', '4', '3', '2', '1', '0']; $quickRes = $this->quic ...
- JS----贪吃蛇游戏
在网上找到的几种例子 <!DOCTYPE html> <html > <head> <meta http-equiv="Content-Type&q ...
- 2018面向对象程序设计(Java)第9周学习指导及要求
2018面向对象程序设计(Java)第9周学习指导及要求(2018.10.25-2018.10.28) 学习目标 1.掌握java异常处理技术: 2.了解断言的用法: 3.了解日志的用途: 4.掌 ...
- 2018面向对象程序设计(Java)第6周学习指导及要求
2018面向对象程序设计(Java) 第6周学习指导及要求(2018.9.29-2018.10.8) 学习目标 深入理解程序设计中算法与程序的关系: 深入理解java程序设计中类与对象的关系: 理 ...