A lot of changes to the fish config, as well as fixing terminal keybindings from nvim not working on kitty, and defining delta as default diff viewer for git

This commit is contained in:
Sergio Laín 2023-08-17 14:33:26 +02:00
parent 300e257f7c
commit 903de02e1e
13 changed files with 127 additions and 39 deletions

View file

@ -2,12 +2,12 @@
"settings": {
"tabs": [
{
"name": "#noticiero",
"url": "/channels/674984102860161025/714477670808813669",
"name": "#multimedia-general",
"url": "/channels/674984102860161025/675014488097030153",
"selected": true,
"currentStatus": "none",
"iconUrl": "https://cdn.discordapp.com/icons/674984102860161025/a4c5c84a118b923dfe68dccd886d1d87.webp?size=40",
"channelId": "714477670808813669"
"channelId": "675014488097030153"
},
{
"name": "#feedback-and-suggestions",
@ -18,12 +18,12 @@
"channelId": "1027703875291062373"
},
{
"name": "#memes",
"url": "/channels/184802320565927936/418478500274765826",
"name": "#archived-suggestions",
"url": "/channels/907385605422448742/923262113500246027/933063572425170976",
"selected": false,
"currentStatus": "none",
"iconUrl": "https://cdn.discordapp.com/icons/184802320565927936/db1c63b64338fa7acfc148f3dd9af243.webp?size=40",
"channelId": "418478500274765826"
"iconUrl": "https://cdn.discordapp.com/icons/907385605422448742/15eb0b4e27967b11f7e72c9ccb133ad1.webp?size=40",
"channelId": "923262113500246027"
},
{
"name": "Friends",

View file

@ -1,14 +1,18 @@
alias code='vscodium'
alias ls='exa --long --header -a --icons'
alias tree='exa --long --header -a --icons --tree'
alias l='exa --long --header -a --icons --git'
alias ls='exa -a --icons'
alias lt='exa --long --header -a --icons --tree --git'
alias ld='exa --long --header -a --icons -D --git'
alias lh='exa --long --header --icons --git'
alias lsh='exa --icons'
alias lth='exa --long --header --icons --tree --git'
alias ldh='exa --long --header --icons -D --git'
alias bruh='genact -s 4'
alias matrix='unimatrix -s 95'
alias q='exit'
alias install='yay -S '
alias uninstall='yay -R '
alias update='yay -Syu'
alias search='pacseek'
alias gpt='tgpt'
alias clock='tty-clock -sbc'
alias files='xplr'
alias sysproc='sysz'
@ -18,9 +22,9 @@ alias audiorestart='systemctl --user restart wireplumber pipewire pipewire-pulse
alias info='tldr'
alias cd='z'
alias disks='duf'
alias cdh='zi'
alias h='zi'
alias vim='nvim'
alias vi='nvim'
alias neovide='env WINIT_UNIX_BACKEND=x11 neovide'
alias fsend='floaterm'
alias dsize='dua i'
alias f='neofetch'

View file

@ -1,8 +1,31 @@
set -xg EDITOR nvim
set -xg VISUAL nvim
set -xg XDG_CONFIG_HOME ~/.config
set -xg XDG_CACHE_HOME ~/.cache
set -xg XDG_DATA_HOME ~/.local/share
set -xg XDG_RUNTIME_DIR ~/.local/run
set -xg XDG_BIN_HOME ~/.local/bin
set -xg XDG_SCRIPT_HOME ~/.local/script
set -xg LANG es_ES.UTF-8
set -xg LC_ALL es_ES.UTF-8
if status is-interactive
# Commands to run in interactive sessions can go here
zoxide init fish | source
. ~/.config/fish/aliases.fish
neofetch
set -x FZF_DEFAULT_OPTS "\
--color=bg+:#363a4f,bg:#24273a,spinner:#f4dbd6,hl:#ed8796 \
--color=fg:#cad3f5,header:#ed8796,info:#c6a0f6,pointer:#f4dbd6 \
--color=marker:#f4dbd6,fg+:#cad3f5,prompt:#c6a0f6,hl+:#ed8796"
set -xg LS_COLORS (vivid generate catppuccin-macchiato)
set fzf_preview_dir_cmd exa --all --color=always
fzf_configure_bindings --directory=\cf
source ~/.config/fish/functions/fzf_git.fish
colorscript random
end
starship init fish | source
starship init fish | source
zoxide init fish | source
source ~/.config/fish/aliases.fish

View file

@ -1,4 +1,4 @@
patrickf1/fzf.fish
franciscolourenco/done
acomagu/fish-async-prompt
joehillen/to-fish
patrickf1/fzf.fish

View file

@ -7,7 +7,7 @@ SETUVAR _fisher_acomagu_2F_fish_2D_async_2D_prompt_files:\x7e/\x2econfig/fish/co
SETUVAR _fisher_franciscolourenco_2F_done_files:\x7e/\x2econfig/fish/conf\x2ed/done\x2efish
SETUVAR _fisher_joehillen_2F_to_2D_fish_files:\x7e/\x2econfig/fish/functions/to\x2efish\x1e\x7e/\x2econfig/fish/conf\x2ed/to\x2efish\x1e\x7e/\x2econfig/fish/completions/to\x2efish
SETUVAR _fisher_patrickf1_2F_fzf_2E_fish_files:\x7e/\x2econfig/fish/functions/_fzf_configure_bindings_help\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_extract_var_info\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_preview_changed_file\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_preview_file\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_report_diff_type\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_report_file_type\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_search_directory\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_search_git_log\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_search_git_status\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_search_history\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_search_processes\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_search_variables\x2efish\x1e\x7e/\x2econfig/fish/functions/_fzf_wrapper\x2efish\x1e\x7e/\x2econfig/fish/functions/fzf_configure_bindings\x2efish\x1e\x7e/\x2econfig/fish/conf\x2ed/fzf\x2efish\x1e\x7e/\x2econfig/fish/completions/fzf_configure_bindings\x2efish
SETUVAR _fisher_plugins:patrickf1/fzf\x2efish\x1efranciscolourenco/done\x1eacomagu/fish\x2dasync\x2dprompt\x1ejoehillen/to\x2dfish
SETUVAR _fisher_plugins:franciscolourenco/done\x1eacomagu/fish\x2dasync\x2dprompt\x1ejoehillen/to\x2dfish\x1epatrickf1/fzf\x2efish
SETUVAR _fisher_upgraded_to_4_4:\x1d
SETUVAR fish_color_autosuggestion:6e738d
SETUVAR fish_color_cancel:ed8796

View file

@ -10,7 +10,7 @@ function _fzf_search_git_log --description "Search the output of git log and pre
git log --no-show-signature --color=always --format=format:$fzf_git_log_format --date=short | \
_fzf_wrapper --ansi \
--multi \
--tiebreak=index \
--scheme=history \
--prompt="Search Git Log> " \
--preview='git show --color=always --stat --patch {1}' \
--query=(commandline --current-token) \

View file

@ -16,7 +16,7 @@ function _fzf_search_history --description "Search command history. Replace the
_fzf_wrapper --read0 \
--print0 \
--multi \
--tiebreak=index \
--scheme=history \
--prompt="Search History> " \
--query=(commandline) \
--preview="echo -- {} | string replace --regex '^.*? │ ' '' | fish_indent --ansi" \

View file

@ -0,0 +1,7 @@
function repos
set selected_dir (find ~/Repos/ -type d -name '.git' -prune | sed 's/\/\.git$//' | sed 's/^\.\///' | fzf)
if test -n "$selected_dir"
cd "$selected_dir"
vim .
end
end

View file

@ -2,7 +2,7 @@
"LazyVim": { "branch": "main", "commit": "aa1cccf230a01bd85d5173f7d87f782fd83caa88" },
"LuaSnip": { "branch": "master", "commit": "409535b8fc54c650eb845b0c35e0cc7f08810284" },
"SchemaStore.nvim": { "branch": "main", "commit": "6ef970b8acd694fb5690d1b8e1d6ad2ea0cc1431" },
"alpha-nvim": { "branch": "main", "commit": "8e05626e073a5a60ffeb8139076520c1eda41d59" },
"alpha-nvim": { "branch": "main", "commit": "7a6b9487dba044a43fde534bf5036f0fda5b6b23" },
"autolist.nvim": { "branch": "main", "commit": "5f70a5f99e96c8fe3069de042abd2a8ed2deb855" },
"bufferline.nvim": { "branch": "main", "commit": "417b303328118b6d836ae330142e88771c48a8a3" },
"catppuccin": { "branch": "main", "commit": "490078b1593c6609e6a50ad5001e7902ea601824" },
@ -18,7 +18,7 @@
"flash.nvim": { "branch": "main", "commit": "967117690bd677cb7b6a87f0bc0077d2c0be3a27" },
"friendly-snippets": { "branch": "main", "commit": "377d45475b49e37460a902d6d569d2093d4037d0" },
"gitsigns.nvim": { "branch": "main", "commit": "55f8fc7b13205d44359080ed00095674c353bd76" },
"glance.nvim": { "branch": "master", "commit": "b78ef99ffda23fa42ce85de50e3fc13a5472ecfd" },
"glance.nvim": { "branch": "master", "commit": "ec19dbdabd47fc2f094f7457a84ae78e7c9b5610" },
"glow.nvim": { "branch": "main", "commit": "8942dfb05794f436af4fbc90a34393f1fd36f361" },
"indent-blankline.nvim": { "branch": "master", "commit": "4541d690816cb99a7fc248f1486aa87f3abce91c" },
"lazy.nvim": { "branch": "main", "commit": "3ad55ae678876516156cca2f361c51f7952a924b" },
@ -36,7 +36,7 @@
"mini.surround": { "branch": "main", "commit": "9d1956b576d7051da3a483b251dfc778121c60db" },
"neo-tree.nvim": { "branch": "v3.x", "commit": "7951701fd21291ac473ea92d3fd57ec5c8bf10bb" },
"neoconf.nvim": { "branch": "main", "commit": "08f146d53e075055500dca35e93281faff95716b" },
"neodev.nvim": { "branch": "main", "commit": "f1f5f840fec7218bd277e7e88e7c539c305f649a" },
"neodev.nvim": { "branch": "main", "commit": "4681d489cce1604a75435494fe278514f9835a87" },
"neoscroll.nvim": { "branch": "master", "commit": "4bc0212e9f2a7bc7fe7a6bceb15b33e39f0f41fb" },
"noice.nvim": { "branch": "main", "commit": "894db25ec726d32047799d4d0a982b701bec453b" },
"nui.nvim": { "branch": "main", "commit": "9e3916e784660f55f47daa6f26053ad044db5d6a" },
@ -52,15 +52,15 @@
"nvim-lspconfig": { "branch": "master", "commit": "0d29cad8de3b2c654315203fc1fe12fde722a18a" },
"nvim-navic": { "branch": "master", "commit": "9c89730da6a05acfeb6a197e212dfadf5aa60ca0" },
"nvim-notify": { "branch": "master", "commit": "ea9c8ce7a37f2238f934e087c255758659948e0f" },
"nvim-scrollview": { "branch": "main", "commit": "7edc3954b7213af8a44671d6dbb6027461cf991e" },
"nvim-scrollview": { "branch": "main", "commit": "e33e4c0ba5bf8fdde4d4d8011f62f6d72669884a" },
"nvim-spectre": { "branch": "master", "commit": "5b39919a2947b1266b3aa34d0b0b14c35523bc69" },
"nvim-terminal.lua": { "branch": "master", "commit": "095f98aaa7265628a72cd2706350c091544b5602" },
"nvim-treesitter": { "branch": "master", "commit": "5f01ffd47843d5030001df81a83c2f9ea1c06d97" },
"nvim-treesitter-context": { "branch": "master", "commit": "d8fd71428e02190d8f75ff915b6cca9e3063992c" },
"nvim-treesitter": { "branch": "master", "commit": "f7bb866405530e863135596900781e73cbf6f4ed" },
"nvim-treesitter-context": { "branch": "master", "commit": "a17c31268b56d53624fdc9cb03a225d4a17cabdb" },
"nvim-treesitter-textobjects": { "branch": "master", "commit": "9e519b6146512c8e2e702faf8ac48420f4f5deec" },
"nvim-ts-autotag": { "branch": "main", "commit": "6be1192965df35f94b8ea6d323354f7dc7a557e4" },
"nvim-ts-context-commentstring": { "branch": "main", "commit": "e9062e2dfb9854e6a927370f2d720de354c88524" },
"nvim-web-devicons": { "branch": "master", "commit": "ab899311f8ae00a47eae8e0879506cead8eb1561" },
"nvim-web-devicons": { "branch": "master", "commit": "cfc8824cc1db316a276b36517f093baccb8e799a" },
"persistence.nvim": { "branch": "main", "commit": "4b8051c01f696d8849a5cb8afa9767be8db16e40" },
"plenary.nvim": { "branch": "master", "commit": "267282a9ce242bbb0c5dc31445b6d353bed978bb" },
"presence.nvim": { "branch": "main", "commit": "87c857a56b7703f976d3a5ef15967d80508df6e6" },

View file

@ -81,8 +81,8 @@ map(
)
map("n", "<A-Left>", "FloatermPrev<CR>", { desc = "Previous Terminal" })
map("n", "<A-Right>", "FloatermNext<CR>", { desc = "Next Terminal" })
map("n", "<c-Return>", ":FloatermToggle<CR>", { desc = "Toggle Terminal" })
map("n", "<c-/>", ":FloatermToggle<CR>", { desc = "Toggle Terminal" })
map("n", "<c-_>", ":FloatermToggle<CR>", { desc = "which_key_ignore" })
vim.keymap.set("n", "<leader>fU", vim.cmd.UndotreeToggle, { noremap = true, silent = true, desc = "Toggle Undotree" })
vim.api.nvim_set_keymap(

View file

@ -147,3 +147,35 @@ symbol = " "
[spack]
symbol = "🅢 "
[palettes.catppuccin_macchiato]
rosewater = "#f4dbd6"
flamingo = "#f0c6c6"
pink = "#f5bde6"
mauve = "#c6a0f6"
red = "#ed8796"
maroon = "#ee99a0"
peach = "#f5a97f"
yellow = "#eed49f"
green = "#a6da95"
teal = "#8bd5ca"
sky = "#91d7e3"
sapphire = "#7dc4e4"
blue = "#8aadf4"
lavender = "#b7bdf8"
text = "#cad3f5"
subtext1 = "#b8c0e0"
subtext0 = "#a5adcb"
overlay2 = "#939ab7"
overlay1 = "#8087a2"
overlay0 = "#6e738d"
surface2 = "#5b6078"
surface1 = "#494d64"
surface0 = "#363a4f"
base = "#24273a"
mantle = "#1e2030"
crust = "#181926"
palette = "catppuccin_flavor"

View file

@ -1,12 +1,12 @@
[user]
name = Sergio Laín
name = Sergio Laín
email = sergiolain11@gmail.com
[safe]
directory = Repos/
[credential "https://github.com"]
username = matt
username = Matt-FTW
[filter "lfs"]
clean = git-lfs clean -- %f
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
@ -15,4 +15,21 @@
[protocol "file"]
allow = always
[credential]
helper = libsecret
helper = libsecret
[core]
editor = nvim
pager = delta
[interactive]
diffFilter = delta --color-only
[delta]
navigate = true # use n and N to move between diff sections
light = false # set to true if you're in a terminal w/ a light background color (e.g. the default macOS terminal)
side-by-side = true
line-numbers = true
syntax-theme = Monokai Extended
[merge]
conflictstyle = diff3
[pager]
blame = delta
[diff]
colorMoved = default

17
.zshrc
View file

@ -114,16 +114,16 @@ eval "$(zoxide init zsh)"
# Some aliases
alias code='vscodium'
alias ls='exa --long --header -a --icons'
alias tree='exa --long --header -a --icons --tree'
alias l='exa --long --header -a --icons --git'
alias ls='exa -a --icons'
alias lt='exa --long --header -a --icons --tree --git'
alias ld='exa --long --header -a --icons -D --git'
alias bruh='genact -s 4'
alias matrix='unimatrix'
alias matrix='unimatrix -s 95'
alias q='exit'
alias install='yay -S '
alias uninstall='yay -R '
alias update='yay -Syu'
alias search='pacseek'
alias gpt='tgpt'
alias clock='tty-clock -sbc'
alias files='xplr'
alias sysproc='sysz'
@ -133,10 +133,15 @@ alias audiorestart='systemctl --user restart wireplumber pipewire pipewire-pulse
alias info='tldr'
alias cd='z'
alias disks='duf'
alias cdh='zi'
alias h='zi'
alias vim='nvim'
alias vi='nvim'
alias fsend='floaterm'
alias dsize='dua i'
PATH=$PATH:/home/matt/.local/bin
TERMINAL=$TERMINAL:/usr/bin/kitty
export EDITOR='nvim'
export LS_COLORS="$(vivid generate catppuccin-macchiato)"
colorscript random