8000 Merge pull request #46 from jkeylu/master · udbmnm/github-cheat-sheet@10efcf3 · GitHub
[go: up one dir, main page]

Skip to content

Commit 10efcf3

Browse files
author
Rafal Chmiel
committed
Merge pull request tiimgreen#46 from jkeylu/master
Add Git alias for logs
2 parents 565cfe7 + 02b3b71 commit 10efcf3

File tree

4 files changed

+4
-0
lines changed

4 files changed

+4
-0
lines changed

README.ja.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -721,6 +721,7 @@ $ git config --global alias.ac 'add -A . && commit'
721721
| `git tags` | `git tag -l` | `git config --global alias.tags 'tag -l'` |
722722
| `git branches` | `git branch -a` | `git config --global alias.branches 'branch -a'` |
723723
| `git remotes` | `git remote -v` | `git config --global alias.remotes 'remote -v'` |
724+
| `git lg` | `git log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --` | `git config --global alias.lg 'log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --'` |
724725

725726
#### コマンドの自動修正
726727
多分今は`git comit`とタイプした場合、以下のような出力を得ることだろう:

README.ko.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -773,6 +773,7 @@ $ git config --global alias.ac 'add -A . && commit'
773773
| `git tags` | `git tag -l` | `git config --global alias.tags 'tag -l'` |
774774
| `git branches` | `git branch -a` | `git config --global alias.branches 'branch -a'` |
775775
| `git remotes` | `git remote -v` | `git config --global alias.remotes 'remote -v'` |
776+
| `git lg` | `git log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --` | `git config --global alias.lg 'log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --'` |
776777

777778
#### Auto-correct
778779

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -720,6 +720,7 @@ Some useful aliases include:
720720
| `git tags` | `git tag -l` | `git config --global alias.tags 'tag -l'` |
721721
| `git branches` | `git branch -a` | `git config --global alias.branches 'branch -a'` |
722722
| `git remotes` | `git remote -v` | `git config --global alias.remotes 'remote -v'` |
723+
| `git lg` | `git log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --` | `git config --global alias.lg 'log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --'` |
723724

724725
*Some Aliases are taken from [@mathiasbynens](https://github.com/mathiasbynens) dotfiles: https://github.com/mathiasbynens/dotfiles/blob/master/.gitconfig*
725726

README.zh-cn.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -704,6 +704,7 @@ $ git config --global alias.ac 'add -A . && commit'
704704
| `git tags` | `git tag -l` | `git config --global alias.tags 'tag -l'` |
705705
| `git branches` | `git branch -a` | `git config --global alias.branches 'branch -a'` |
706706
| `git remotes` | `git remote -v` | `git config --global alias.remotes 'remote -v'` |
707+
| `git lg` | `git log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --` | `git config --global alias.lg 'log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --'` |
707708

708709
#### 自动更正
709710
如果键入 `git comit` 你会看到如下输出:

0 commit comments

Comments
 (0)
0