diff --git a/config/bat/config b/config/bat/config new file mode 100644 index 0000000..d7f71fb --- /dev/null +++ b/config/bat/config @@ -0,0 +1 @@ +--theme="Catppuccin-mocha" diff --git a/config/bat/themes/Catppuccin-mocha.tmTheme b/config/bat/themes/Catppuccin-mocha.tmTheme new file mode 100644 index 0000000..3b9b72c --- /dev/null +++ b/config/bat/themes/Catppuccin-mocha.tmTheme @@ -0,0 +1,959 @@ + + + + + name + Catppuccin + settings + + + settings + + foreground + #cdd6f4 + background + #1e1e2e + caret + #bac2de + invisibles + #a6adc8 + gutterForeground + #9399b2 + gutterForegroundHighlight + #a6e3a1 + lineHighlight + #585b70 + selection + #6c7086 + selectionBorder + #1e1e2e + activeGuide + #fab387 + findHighlightForeground + #181825 + findHighlight + #f9e2af + bracketsForeground + #9399b2 + bracketContentsForeground + #9399b2 + + + + name + Comment + scope + comment + settings + + foreground + #6c7086 + fontStyle + italic + + + + name + String + scope + string + settings + + foreground + #a6e3a1 + fontStyle + + + + + name + String regex + scope + string.regexp + settings + + foreground + #fab387 + fontStyle + + + + + name + Number + scope + constant.numeric + settings + + foreground + #fab387 + fontStyle + + + + + name + Boolean + scope + constant.language.boolean + settings + + foreground + #fab387 + fontStyle + bold italic + + + + name + Built-in constant + scope + constant.language + settings + + foreground + #b4befe + fontStyle + italic + + + + name + Built-in function + scope + support.function.builtin + settings + + foreground + #fab387 + fontStyle + italic + + + + name + User-defined constant + scope + variable.other.constant + settings + + foreground + #fab387 + fontStyle + + + + + name + Variable + scope + variable + settings + + + + name + Keyword + scope + keyword + settings + + foreground + #f38ba8 + fontStyle + italic + + + + name + Conditional/loop + scope + keyword.control.loop, keyword.control.conditional, keyword.control.c++ + settings + + foreground + #cba6f7 + fontStyle + bold + + + + name + Return + scope + keyword.control.return, keyword.control.flow.return + settings + + foreground + #f5c2e7 + fontStyle + bold + + + + name + Exception + scope + support.type.exception + settings + + foreground + #fab387 + fontStyle + italic + + + + name + Operator + scope + keyword.operator, punctuation.accessor + settings + + foreground + #89dceb + fontStyle + bold + + + + name + Punctuation separator + scope + punctuation.separator + settings + + foreground + #94e2d5 + fontStyle + + + + + name + Punctuation terminator + scope + punctuation.terminator + settings + + foreground + #94e2d5 + fontStyle + + + + + name + Punctuation bracket + scope + punctuation.section + settings + + foreground + #9399b2 + fontStyle + + + + + name + Include + scope + keyword.control.import.include + settings + + foreground + #94e2d5 + fontStyle + italic + + + + name + Storage + scope + storage + settings + + foreground + #f38ba8 + fontStyle + + + + + name + Storage type + scope + storage.type + settings + + foreground + #f9e2af + fontStyle + italic + + + + name + Storage modifier + scope + storage.modifier + settings + + foreground + #f38ba8 + fontStyle + + + + + name + Storage type namespace + scope + entity.name.namespace, meta.path + settings + + foreground + #f5e0dc + fontStyle + italic + + + + name + Storage type class + scope + storage.type.class + settings + + foreground + #f5e0dc + fontStyle + italic + + + + name + Label + scope + entity.name.label + settings + + foreground + #89b4fa + fontStyle + + + + + name + Keyword class + scope + keyword.declaration.class + settings + + foreground + #f38ba8 + fontStyle + italic + + + + name + Class name + scope + entity.name.class, meta.toc-list.full-identifier + settings + + foreground + #89dceb + fontStyle + + + + + name + Inherited class + scope + entity.other.inherited-class + settings + + foreground + #89dceb + fontStyle + italic + + + + name + Function name + scope + entity.name.function, variable.function + settings + + foreground + #89b4fa + fontStyle + italic + + + + name + Function macro + scope + entity.name.function.preprocessor + settings + + foreground + #f38ba8 + fontStyle + + + + + name + Macro directive - ifdef + scope + keyword.control.import + settings + + foreground + #f38ba8 + fontStyle + + + + + name + Constructor + scope + entity.name.function.constructor, entity.name.function.destructor + settings + + foreground + #b4befe + fontStyle + + + + + name + Function argument + scope + variable.parameter.function + settings + + foreground + #f5e0dc + fontStyle + italic + + + + name + Function declaration + scope + keyword.declaration.function + settings + + foreground + #eba0ac + fontStyle + italic + + + + name + Library function + scope + support.function + settings + + foreground + #89dceb + fontStyle + + + + + name + Library constant + scope + support.constant + settings + + foreground + #89b4fa + fontStyle + + + + + name + Library class/type + scope + support.type, support.class + settings + + foreground + #89b4fa + fontStyle + italic + + + + name + Library variable + scope + support.other.variable + settings + + fontStyle + + + + + name + Variable function + scope + variable.function + settings + + foreground + #89b4fa + fontStyle + italic + + + + name + Variable parameter + scope + variable.parameter + settings + + foreground + #f5e0dc + fontStyle + italic + + + + name + Variable other + scope + variable.other + settings + + foreground + #cdd6f4 + fontStyle + italic + + + + name + Variable field + scope + variable.other.member + settings + + foreground + #f5e0dc + fontStyle + + + + + name + Variable language + scope + variable.language + settings + + foreground + #94e2d5 + fontStyle + + + + + name + Tag name + scope + entity.name.tag + settings + + foreground + #fab387 + fontStyle + + + + + name + Tag attribute + scope + entity.other.attribute-name + settings + + foreground + #cba6f7 + fontStyle + italic + + + + name + Tag delimiter + scope + punctuation.definition.tag + settings + + foreground + #eba0ac + fontStyle + + + + + name + Markdown URL + scope + markup.underline.link.markdown + settings + + foreground + #f5e0dc + fontStyle + italic underline + + + + name + Markdown reference + scope + meta.link.inline.description + settings + + foreground + #b4befe + fontStyle + bold + + + + name + Markdown literal + scope + comment.block.markdown, meta.code-fence, markup.raw.code-fence, markup.raw.inline + settings + + foreground + #94e2d5 + fontStyle + italic + + + + name + Markdown title + scope + punctuation.definition.heading, entity.name.section + settings + + foreground + #89b4fa + fontStyle + bold + + + + name + Markdown emphasis + scope + markup.italic + settings + + foreground + #eba0ac + fontStyle + italic + + + + name + Markdown strong + scope + markup.bold + settings + + foreground + #eba0ac + fontStyle + bold + + + + name + Escape + scope + constant.character.escape + settings + + foreground + #f5c2e7 + fontStyle + + + + + name + Bash built-in function + scope + source.shell.bash meta.function.shell meta.compound.shell meta.function-call.identifier.shell + settings + + foreground + #f5c2e7 + fontStyle + + + + + name + Bash parameter + scope + variable.language.shell + settings + + foreground + #f38ba8 + fontStyle + italic + + + + name + Lua field + scope + source.lua meta.function.lua meta.block.lua meta.mapping.value.lua meta.mapping.key.lua string.unquoted.key.lua + settings + + foreground + #b4befe + fontStyle + italic + + + + name + Lua constructor + scope + source.lua meta.function.lua meta.block.lua meta.mapping.key.lua string.unquoted.key.lua + settings + + foreground + #f2cdcd + fontStyle + + + + + name + Java constant + scope + entity.name.constant.java + settings + + foreground + #94e2d5 + fontStyle + + + + + name + CSS property + scope + support.type.property-name.css + settings + + foreground + #f2cdcd + fontStyle + italic + + + + name + CSS constant + scope + support.constant.property-value.css + settings + + foreground + #cdd6f4 + fontStyle + + + + + name + CSS suffix + scope + constant.numeric.suffix.css, keyword.other.unit.css + settings + + foreground + #94e2d5 + fontStyle + italic + + + + name + CSS variable property + scope + variable.other.custom-property.name.css, support.type.custom-property.name.css, punctuation.definition.custom-property.css + settings + + foreground + #94e2d5 + fontStyle + + + + + name + SCSS tag + scope + entity.name.tag.css + settings + + foreground + #b4befe + fontStyle + + + + + name + SASS variable + scope + variable.other.sass + settings + + foreground + #94e2d5 + fontStyle + + + + + name + Invalid + scope + invalid + settings + + foreground + #cdd6f4 + background + #f38ba8 + fontStyle + + + + + name + Invalid deprecated + scope + invalid.deprecated + settings + + foreground + #cdd6f4 + background + #cba6f7 + fontStyle + + + + + name + Diff header + scope + meta.diff, meta.diff.header + settings + + foreground + #6c7086 + fontStyle + + + + + name + Diff deleted + scope + markup.deleted + settings + + foreground + #f38ba8 + fontStyle + + + + + name + Diff inserted + scope + markup.inserted + settings + + foreground + #a6e3a1 + fontStyle + + + + + name + Diff changed + scope + markup.changed + settings + + foreground + #f9e2af + fontStyle + + + + + name + Message error + scope + message.error + settings + + foreground + #f38ba8 + fontStyle + + + + + uuid + 4d0379b5-ef82-467b-b8b8-365889420646 + colorSpaceName + sRGB + semanticClass + theme.dark.Catppuccin + author + BrunDerSchwarzmagier + + diff --git a/config/delta/themes.gitconfig b/config/delta/themes.gitconfig new file mode 100644 index 0000000..c1a4f18 --- /dev/null +++ b/config/delta/themes.gitconfig @@ -0,0 +1,35 @@ +[delta "mellow-barbet"] + # author: https://github.com/kvrohit + # To configure terminal colors see https://github.com/kvrohit/mellow.nvim#terminals + dark = true + syntax-theme = Catppuccin-mocha + line-numbers = true + file-style = brightwhite + file-decoration-style = none + file-added-label = [A] + file-copied-label = [==] + file-modified-label = [M] + file-removed-label = [D] + file-renamed-label = [->] + hunk-header-decoration-style = "#3e3e43" box ul + plus-style = brightgreen black + plus-emph-style = black green + minus-style = brightred black + minus-emph-style = black red + line-numbers-minus-style = brightred + line-numbers-plus-style = brightgreen + line-numbers-left-style = "#3e3e43" + line-numbers-right-style = "#3e3e43" + line-numbers-zero-style = "#57575f" + zero-style = syntax + whitespace-error-style = black bold + blame-code-style = syntax + blame-palette = "#161617" "#1b1b1d" "#2a2a2d" "#3e3e43" + merge-conflict-begin-symbol = ~ + merge-conflict-end-symbol = ~ + merge-conflict-ours-diff-header-style = yellow bold + merge-conflict-ours-diff-header-decoration-style = "#3e3e43" box + merge-conflict-theirs-diff-header-style = yellow bold + merge-conflict-theirs-diff-header-decoration-style = "#3e3e43" box + +# vim: ft=gitconfig diff --git a/config/zsh/plugins.toml b/config/zsh/plugins.toml index 682b073..3b0cb29 100644 --- a/config/zsh/plugins.toml +++ b/config/zsh/plugins.toml @@ -41,7 +41,12 @@ apply = ["defer"] [plugins.zsh-vi-mode] github = 'jeffreytse/zsh-vi-mode' +[plugins.git-fuzzy] +github = "bigH/git-fuzzy" +dir = "bin" +apply = ["PATH"] + # Initialize completion stuff -# This should be defined last to have completions work properly +# This should be defined last for completions to work properly [plugins.compinit] inline = "autoload -Uz compinit && compinit" diff --git a/config/zsh/plugins/aliases.zsh b/config/zsh/plugins/aliases.zsh index 91621cc..3330d3c 100644 --- a/config/zsh/plugins/aliases.zsh +++ b/config/zsh/plugins/aliases.zsh @@ -10,6 +10,7 @@ alias egrep='egrep --color=auto --exclude-dir={.bzr,CVS,.git,.hg,.svn,.idea,.tox alias fgrep='fgrep --color=auto --exclude-dir={.bzr,CVS,.git,.hg,.svn,.idea,.tox}' alias grep='grep --color=auto --exclude-dir={.bzr,CVS,.git,.hg,.svn,.idea,.tox}' alias gti='git' # I quite often mistype `git` as `gti` +alias gf='git fuzzy' alias pp='pnpm' alias px='pnpm dlx' alias pe='pnpm exec' diff --git a/config/zsh/plugins/fzf.zsh b/config/zsh/plugins/fzf.zsh index cc1a8b6..18826bd 100644 --- a/config/zsh/plugins/fzf.zsh +++ b/config/zsh/plugins/fzf.zsh @@ -11,6 +11,7 @@ source "${PREFIX:-/usr}"/share/fzf/key-bindings.zsh # Use fd as primary indexer globally export FZF_DEFAULT_COMMAND="fd --type f --strip-cwd-prefix --follow" +export FZF_DEFAULT_OPTS="--bind 'alt-w:toggle-preview-wrap'" export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND" export FZF_ALT_C_OPTS="--height 100% --preview 'exa --tree {}'" alias fh='(cd $HOME; fv)' @@ -27,7 +28,7 @@ function fv() { # Invoke fzf and select files local files=() - FZF_DEFAULT_OPTS="$opts" fzf | while IFS= read -r file; do files+=("$file"); done + FZF_DEFAULT_OPTS="$FZF_DEFAULT_OPTS $opts" fzf | while IFS= read -r file; do files+=("$file"); done [[ -n "${files[1]}" ]] && vim ${files[@]} } diff --git a/scripts/git-setup.sh b/scripts/git-setup.sh index 1af18ec..eac32b4 100644 --- a/scripts/git-setup.sh +++ b/scripts/git-setup.sh @@ -114,6 +114,22 @@ git_aliases() { ( git config --global alias.us 'reset HEAD' ); } +git_plugins() { + # https://github.com/dandavison/delta + if command -v delta &>/dev/null; then + git config --global core.pager delta + git config --global interactive.diffFilter "delta --color-only" + git config --global merge.conflictstyle diff3 + git config --global diff.colorMoved default + + # delta config + git config --global delta.light false + git config --global delta.line-numbers true + git config --global delta.navigate true + git config --global delta.features mellow-barbet # theme + fi +} + # Initial git config setup git_setup() { ( git config --global user.name "Saurabh Charde" @@ -124,4 +140,5 @@ git_setup() { ( gpg_setup git_aliases + git_plugins ); }