Skip to content

Commit f4f4eef

Browse files
Merge pull request #395 from dotiful/patch-1
Update pro-tips.md
2 parents 75587c6 + c94e4de commit f4f4eef

File tree

5 files changed

+18
-14
lines changed

5 files changed

+18
-14
lines changed

README.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,39 +52,39 @@ git config --global color.diff.whitespace "red reverse"
5252

5353
Should the first block of an empty line be colored. (Default: true)
5454

55-
```
55+
```shell
5656
git config --bool --global diff-so-fancy.markEmptyLines false
5757
```
5858

5959
### changeHunkIndicators
6060

6161
Simplify git header chunks to a more human readable format. (Default: true)
6262

63-
```
63+
```shell
6464
git config --bool --global diff-so-fancy.changeHunkIndicators false
6565
```
6666

6767
### stripLeadingSymbols
6868

6969
Should the pesky `+` or `-` at line-start be removed. (Default: true)
7070

71-
```
71+
```shell
7272
git config --bool --global diff-so-fancy.stripLeadingSymbols false
7373
```
7474

7575
### useUnicodeRuler
7676

7777
By default, the separator for the file header uses Unicode line-drawing characters. If this is causing output errors on your terminal, set this to `false` to use ASCII characters instead. (Default: true)
7878

79-
```
79+
```shell
8080
git config --bool --global diff-so-fancy.useUnicodeRuler false
8181
```
8282

8383
### rulerWidth
8484

8585
By default, the separator for the file header spans the full width of the terminal. Use this setting to set the width of the file header manually.
8686

87-
```
87+
```shell
8888
git config --global diff-so-fancy.rulerWidth 47 # git log's commit header width
8989
```
9090

@@ -109,6 +109,10 @@ Pull requests are quite welcome, and should target the [`next` branch](https://g
109109
* [Hacking and Testing](hacking-and-testing.md)
110110
* [History](history.md)
111111

112+
## Alternatives
113+
114+
* https://github.com/dandavison/delta
115+
112116
## License
113117

114118
MIT

hacking-and-testing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,4 @@ You can lint your scripts via shellcheck, our CI bots will also check.
3333

3434
```sh
3535
brew install shellcheck
36-
shellcheck diff-so-fancy update-deps.sh
36+
shellcheck *.sh

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "diff-so-fancy",
3-
"version": "1.2.5",
3+
"version": "1.3.0",
44
"description": "Good-lookin' diffs with diff-highlight and more",
55
"bin": {
66
"diff-so-fancy": "diff-so-fancy"

pro-tips.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ You can do also do a one-off or a specific `diff-so-fancy` alias:
77
git diff --color | diff-so-fancy
88

99
git config --global alias.dsf '!f() { [ -z "$GIT_PREFIX" ] || cd "$GIT_PREFIX" '\
10-
'&& git diff --color "$@" | diff-so-fancy | less --tabs=4 -RFX; }; f'
10+
'&& git diff --color "$@" | diff-so-fancy | less --tabs=4 -RFXS; }; f'
1111
```
1212

1313
#### Opting-out
@@ -34,19 +34,19 @@ You can pre-seed your `less` pager with a search pattern, so you can move
3434
between files with `n`/`N` keys:
3535
```ini
3636
[pager]
37-
diff = diff-so-fancy | less --tabs=4 -RFX --pattern '^(Date|added|deleted|modified): '
37+
diff = diff-so-fancy | less --tabs=4 -RFXS --pattern '^(Date|added|deleted|modified): '
3838
```
3939

4040
#### Zsh plugin providing diff-so-fancy
4141

4242
Zsh plugin [zdharma/zsh-diff-so-fancy](https://github.com/zdharma/zsh-diff-so-fancy) has this
4343
project as a submodule so installing the plugin installs `diff-so-fancy`. The plugin provides
44-
subcommand `git dsf` out of the box. Installation with Zplugin, Zplug and Zgen:
44+
subcommand `git dsf` out of the box. Installation with Zinit, Zplug and Zgen:
4545

4646
```zsh
47-
# Zplugin
48-
zplugin ice as"program" pick"bin/git-dsf"
49-
zplugin light zdharma/zsh-diff-so-fancy
47+
# zinit
48+
zinit ice lucid as"program" pick"bin/git-dsf"
49+
zinit load zdharma/zsh-diff-so-fancy
5050

5151
# Or zplug
5252
zplug "zdharma/zsh-diff-so-fancy", as:command, use:bin/git-dsf

0 commit comments

Comments
 (0)