mirror of
https://github.com/zdharma-continuum/zsh-diff-so-fancy.git
synced 2026-09-10 07:16:24 -04:00
diff-so-fancy submodule, symlink in bin/, README.md
This commit is contained in:
parent
b88cf03aea
commit
8ba67c35b8
3
.gitmodules
vendored
Normal file
3
.gitmodules
vendored
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
[submodule "diff-so-fancy"]
|
||||
path = diff-so-fancy
|
||||
url = https://github.com/so-fancy/diff-so-fancy
|
||||
36
README.md
Normal file
36
README.md
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
# Zsh-Diff-So-Fancy
|
||||
|
||||
The project [so-fancy/diff-so-fancy](https://github.com/so-fancy/diff-so-fancy) is very
|
||||
interesting, however I find it difficult to a) install it, b) hook it up to git.
|
||||
|
||||
For the a), I just like to install things as user, in home directory, not system-wide via
|
||||
package manager. So even if the package exists (like it is in e.g. Homebrew for OS X, it
|
||||
has `diff-so-fancy`), I try to not use it. Think about remote shell accounts, is it good
|
||||
to ask every system administrator to install your favorite packages?
|
||||
|
||||
With this Zsh plugin, you simply add two lines to `.zshrc`:
|
||||
|
||||
```zsh
|
||||
zplugin ice as"program" pick"bin/git-dsf"
|
||||
zplugin light zdharma/zsh-diff-so-fancy
|
||||
```
|
||||
|
||||
This will install `diff-so-fancy` on every account where you use Zshell, and automatically
|
||||
equip `git` with subcommand `dsf`. No need to use system package manager and to configure
|
||||
`git`. Of course, if you have the following standard line in your `.gitconfig`, it will
|
||||
still work normally:
|
||||
|
||||
```
|
||||
[core]
|
||||
pager = diff-so-fancy | less -FXRi
|
||||
```
|
||||
|
||||
(because this plugin adds `diff-so-fancy` to `$PATH`).
|
||||
|
||||
# A Few Details
|
||||
|
||||
[so-fancy/diff-so-fancy](https://github.com/so-fancy/diff-so-fancy) is cloned from
|
||||
Github as submodule. The plugin has `bin/git-dsf` script which adds subcommand `dsf`
|
||||
to git. That's basically everything needed: convenient way of installing (single Zsh
|
||||
plugin manager invocation), updating (Zsh plugin managers can easily update) and
|
||||
integrating with `git`.
|
||||
1
bin/diff-so-fancy
Symbolic link
1
bin/diff-so-fancy
Symbolic link
|
|
@ -0,0 +1 @@
|
|||
../diff-so-fancy/diff-so-fancy
|
||||
1
diff-so-fancy
Submodule
1
diff-so-fancy
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit 0d2492c0cc81c11588040982f9544b6be8541bcb
|
||||
Loading…
Reference in a new issue