"Getting Started with git 13" Ubuntu and Git-jackystudio-Blog channel-csdn.net
Previously, we were working with git under the Windows platform. Now let's try Ubuntu instead! Prepare your Ubuntu or Linux system first. The 13.04 version of the virtual machine environment is used here
use git under 1.Ubuntu
Open Terminal (ctrl+alt+t). There's no Git bash under Ubuntu, it's all about using terminal.
1.1. Install SSH
?
[CPP]? view
Plaincopy?
- Sudo?apt-get?install? Ssh??
?
1.2. Install git
?
[CPP]? view
Plaincopy?
- Sudo?apt-get?install?git??
?
1.3. Set user name and mailbox
This is the same as under Windows.
1.4. Initialize git and make a commit
These actions include that the rest of the operations are consistent with the use of Windows and are not duplicated later. See the previous sections.
2. Using Ubuntu to build a server
Now the GIT service is better to have GitHub and BitBucket, the latter can also establish a private remote warehouse, as well as the Chinese interface, but if you want to build a local network server, how to do?
2.1. Building a server remote repository
2.2. Push local modifications to the server repository
?
[CPP]? view
Plaincopy?
- #修改本地Jackydata01
- $SNBSP, Echo? "Hello?" Ubuntu "?? Jackydata01??
- ??
- #. Submit changes to
- $SNBSP, git?commit?-a?-m? "Helloubuntu" ??
- ??
- #添加Ubuntu服务器远程仓库 ??
- $Snbsp; [email protected]:srv.git??]
- ??
- #推送到ubuntu服务器远程仓库 ??
- $Snbsp; Git?push?ubuntu?master??
"Getting Started with git 13" Ubuntu and Git