In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
Editor to share with you what are the commands related to Git. I hope you will get something after reading this article. Let's discuss it together.
Global Settin
Git config-- global user.name "zyl" git config-- global user.email xxx@xxx.comgit config-- list check your git setting git clone xxxxxx.git
Add a new file
Vim demo.txtgit add demo.txt adds a new file git commit-m 'this is first commit' to submit to the local warehouse and sets the comment git push to convert this to the main branch git rm xxx.txt delete file git commit-m' xxxx'; submit to the warehouse git pushgit pull pull file git log-all log git branch view all branches git log-stat xxx view the submission information of a fulcrum find .git / objects-type f view all branches
Ali Cloud related commands:
Command line instruction
Git Global Settings
Git config-global user.name "z1577121881" git config-global user.email "1577121881@qq.com"
Create a new version library
Git clone git@code.aliyun.com:z1577121881/tantou.gitcd tantoutouch README.mdgit add README.mdgit commit-m "add README" git push-u origin master
Existing folder or Git repository
Cd existing_foldergit initgit remote add origin git@code.aliyun.com:z1577121881/tantou.gitgit add. Git commit-am "some information you need to fill in" git push-u origin master
Code cloud related commands
Set global information
Git config-global user.name "your name" git config-global user.email "your Email" clone and pushgit clone http://xxxx/xxxx.git
Create a feature branch
Git checkout-b $feature_name
Submit code
Git commit-am "this is commit"
Push to specified branch
Git push origin $feature_name
For convenience, it is best to add a public key to git.
You can generate it with the following command
Ssh-keygen-t rsa-C "xxxxx@xxxxx.com" # Creates a new ssh key using the provided email# Generating public/private rsa key pair...
View public key
Cat / .ssh/id_rsa.pub# ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC6eNtGpNGwstc....
After adding, enter in the terminal (Terminal)
Ssh-T git@git.oschina.net
If Welcome to Git@OSC is returned, yourname!
After reading this article, I believe you have a certain understanding of "Git-related commands". If you want to know more about it, you are welcome to follow the industry information channel. Thank you for your reading!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.