Revert "Use delta as git diff pager"

This reverts commit b37187f79e.
This commit is contained in:
coolneng 2022-10-18 14:52:02 +02:00
parent 1a508bd19e
commit 4c6be29281
Signed by: coolneng
GPG Key ID: 9893DA236405AF57
3 changed files with 7 additions and 14 deletions

View File

@ -4,7 +4,6 @@
signingkey = 9893DA236405AF57 signingkey = 9893DA236405AF57
[core] [core]
excludesfile = /home/coolneng/.config/git/global_gitignore excludesfile = /home/coolneng/.config/git/global_gitignore
pager = delta
[credential] [credential]
helper = !pass-git-helper $@ helper = !pass-git-helper $@
[commit] [commit]
@ -18,13 +17,11 @@
[filter "git-ignore-line.sh"] [filter "git-ignore-line.sh"]
clean = /home/coolneng/.dotfiles/scripts/.local/share/scripts/git-ignore-line.sh clean = /home/coolneng/.dotfiles/scripts/.local/share/scripts/git-ignore-line.sh
smudge = cat smudge = cat
[interactive]
diffFilter = delta --color-only
[add.interactive] [add.interactive]
useBuiltin = false # required for git 2.37.0 useBuiltin = false # required for git 2.37.0
[delta]
navigate = true # use n and N to move between diff sections
[merge] [merge]
conflictstyle = diff3 conflictstyle = diff3
[diff] [diff]
colorMoved = default colorMoved = default
[add.interactive]
useBuiltin = false # required for git 2.37.0

View File

@ -992,6 +992,11 @@ map kitty_mod+delete clear_terminal reset active
confirm_os_window_close 0 confirm_os_window_close 0
<<<<<<< HEAD
||||||| b37187f (Use delta as git diff pager)
=======
>>>>>>> parent of b37187f (Use delta as git diff pager)

View File

@ -5,20 +5,11 @@ capitalize() {
printf '%s' "$1" | tail -c '+2' printf '%s' "$1" | tail -c '+2'
} }
modify_delta() {
if [ "$1" = "light" ]; then
sed -e "s/light = false/light = true/" -e "s/OneHalfDark/OneHalfLight/" -i ~/.config/git/config
else
sed -e "s/light = true/light = false/" -e "s/OneHalfLight/OneHalfDark/" -i ~/.config/git/config
fi
}
change_theme() { change_theme() {
sed -i "s/iceberg_$1/iceberg_$2/" ~/.config/kitty/kitty.conf sed -i "s/iceberg_$1/iceberg_$2/" ~/.config/kitty/kitty.conf
sed -i "s/bg=$1/bg=$2/" ~/.config/nvim/init.vim sed -i "s/bg=$1/bg=$2/" ~/.config/nvim/init.vim
sed -i "s/iceberg_$1/iceberg_$2/" ~/.dotfiles/tmux/.tmux.conf sed -i "s/iceberg_$1/iceberg_$2/" ~/.dotfiles/tmux/.tmux.conf
sed -i "s/iceberg_$1/iceberg_$2/" ~/.config/zathura/zathurarc sed -i "s/iceberg_$1/iceberg_$2/" ~/.config/zathura/zathurarc
modify_delta "$2"
kitty +kitten themes --reload-in=all "Iceberg $(capitalize "$2")" kitty +kitten themes --reload-in=all "Iceberg $(capitalize "$2")"
tmux source-file ~/.tmux.conf tmux source-file ~/.tmux.conf
nvr --remote-send ":source ~/.config/nvim/init.vim <CR> :set nonumber <CR> :set norelativenumber <CR>" nvr --remote-send ":source ~/.config/nvim/init.vim <CR> :set nonumber <CR> :set norelativenumber <CR>"