[转]git命令简写、简称、缩写

一些常用简写命令:

1
2
3
4
5
6
git st # git status
git ci  # git commit
git br # git branch
git co # git checkout
git mg # git merge
git line # git log --oneline

  

当然,你也可以直接在git中敲命令,将这些简写添加到git配置中

1
git config --global -e

  

然后,可以插入下面的配置:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
[alias]
    st = status
    co = checkout
    br = branch
    mg = merge
    ci = commit
    md = commit --amend
    dt = difftool
    mt = mergetool
    last = log -1 HEAD
    cf = config
    line = log --oneline
    latest = for-each-ref --sort=-committerdate --format='%(committerdate:short) %(refname:short) [%(committername)]'
  
    ls = log --pretty=format:\"%C(yellow)%h %C(blue)%ad %C(red)%d %C(reset)%s %C(green)[%cn]\" --decorate --date=short
    hist = log --pretty=format:\"%C(yellow)%h %C(red)%d %C(reset)%s %C(green)[%an] %C(blue)%ad\" --topo-order --graph --date=short
    type = cat-file -t
    dump = cat-file -p
    

  

 

 

 

---

来源:https://blog.csdn.net/u010883578/article/details/103137418

 

posted @   悟透  阅读(881)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· 分享4款.NET开源、免费、实用的商城系统
· 全程不用写代码,我用AI程序员写了一个飞机大战
· MongoDB 8.0这个新功能碉堡了,比商业数据库还牛
· 白话解读 Dapr 1.15:你的「微服务管家」又秀新绝活了
· 记一次.NET内存居高不下排查解决与启示
点击右上角即可分享
微信分享提示