Skip to content

Commit f222ff7

Browse files
Merge pull request #389 from rmacklin/configure-pager-and-alias
Update pro-tips.md to use a simpler alias and corresponding pager
2 parents 7bd74e3 + 2651b15 commit f222ff7

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

pro-tips.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,14 @@
22

33
#### One-off fanciness or a specific diff-so-fancy alias
44

5-
You can do also do a one-off or a specific `diff-so-fancy` alias:
5+
You can do also do a one-off:
66
```shell
77
git diff --color | diff-so-fancy
8-
9-
git config --global alias.dsf '!f() { [ -z "$GIT_PREFIX" ] || cd "$GIT_PREFIX" '\
10-
'&& git diff --color "$@" | diff-so-fancy | less --tabs=4 -RFXS; }; f'
8+
```
9+
or configure an alias and a corresponding pager to use `diff-so-fancy`:
10+
```shell
11+
git config --global alias.dsf "diff --color"
12+
git config --global pager.dsf "diff-so-fancy | less --tabs=4 -RFXS"
1113
```
1214

1315
#### Opting-out

0 commit comments

Comments
 (0)