# 2024-10-10
Table of Contents
2024-10-10
git diff-highlight を有効にする
$ git config --global pager.log "diff-highlight | less"$ git config --global pager.show "diff-highlight | less"$ git config --global pager.diff "diff-highlight | less"
# ~/.gitconfig
[pager] log = diff-highlight | less show = diff-highlight | less diff = diff-highlight | less
# そのままだと not found が出るのでシンボリックリンクを貼った$ sudo ln -s /usr/share/doc/git/contrib/diff-highlight/diff-highlight /usr/local/bin/diff-highlight
# ~/.bashrc に書くのだとうまくいかなかったexport PATH="$PATH:/usr/share/doc/git/contrib/diff-highlight/diff-highlight"
# Permission denied が出るので$ sudo chmod +x /usr/share/doc/git/contrib/diff-highlight/diff-highlight
参考:
https://tech-broccoli.life/articles/engineer/enable-diff-highlight