Compare commits

...

7 commits

Author SHA1 Message Date
0a6f591817
jj: Rename head log alias to jlh
`jlh` shows all heads (leaf changes) without any additional commits,
while `JLH` shows all heads with 3 ancestor commits each for some
additional context.
2025-12-12 23:47:52 +01:00
4e06f2e23b
zsh: Remove carapace
It was a nice experiment but carapace and fzf-tab simply do not work
together currently.

The main issue is double-backlashes whenever a file with spaces it
selected. This is a _huge_ issue since it simply does not allow
completing _any_ file with spaces and is extremely tedious.

Issue tracked here:

https://github.com/carapace-sh/carapace-bin/issues/2667
https://github.com/Aloxaf/fzf-tab/issues/503

There are smaller issues like `cd folder/` completion adding a space
after the word so you cannot complete further 'into' the directory, and
some other small problems.

All of that only even works with a 'empty query string' hack to get the
two working together in the first place:

https://github.com/carapace-sh/carapace-bin/issues/2819#issuecomment-3092307945%3E

Ultimately it just seems not worth it to me.
2025-12-12 23:47:52 +01:00
93a8adb02b
xdg: Move music and videos into right media dir
Default to have both videos and audio (music) in the correct dirs under
`~/media/{audio,video}` directly. This makes logical sense but also fits
much better to my current organization scheme.
2025-12-12 23:47:51 +01:00
23cb8d32e5
nvim: Add spider plugin for better web key movement
Improves the 'subword' and punctuation jumps of the w/e/b keys, by
adhering to snake_case and CamelCase words and jumping to subparts of
them, as well as ignoring 'useless' punctuation when jumping.
2025-12-12 23:47:50 +01:00
585a48ff94
nvim: Add mapping to flash.nvim current word
Use <S> to jump to any word that is the same as the current word under
the cursor using flash.

Moved the previous flash treesitter binding and updated it to
`treesitter_search` so any word in the current buffer view can be used
as starting point for a tresitter-based selection. Mapping moved to <R>
as is (somewhat) mimics the <yr...> remote-based mappings for flash.
2025-12-12 23:47:50 +01:00
ab3a104a85
nvim: Move flash.nvim and spellsync out of base modules
Since flash, while integral to my day-to-day editing is not about
providing a _base_ to other plugins, but editing, it moved to the
editing module.

Spellsync is only really useful in a prose context in my workflows, so
this is where it went.
2025-12-12 23:47:49 +01:00
b7d2fdea3d
nvim: Add csvview for tablelike csv files
Gives a very nice viewing and editing experience for csv files. Not sure
what the performance impact is for bigger files, but certainly is worth
it for the smaller ones.
Automatically switches on the view for `.csv` and `.tsv` files.

Additionally, adds some keymaps whenever a csv-like file is loaded (i.e.
when the `CsvViewEnable` mode is on):

<s-j> and <s-k> to traverse up and down rows, <s-l> and <s-k> to
traverse columns left and right. Adds a 'field' textobject (`if` and
`af`), though only a single field can currently be changed at once.
2025-12-12 23:47:49 +01:00
16 changed files with 97 additions and 80 deletions

View file

@ -8,7 +8,7 @@
XDG_DESKTOP_DIR="$HOME/desktop" XDG_DESKTOP_DIR="$HOME/desktop"
XDG_DOCUMENTS_DIR="$HOME/documents" XDG_DOCUMENTS_DIR="$HOME/documents"
XDG_DOWNLOAD_DIR="$HOME/downloads" XDG_DOWNLOAD_DIR="$HOME/downloads"
XDG_MUSIC_DIR="$HOME/media/audio/music" XDG_MUSIC_DIR="$HOME/media/music"
XDG_PICTURES_DIR="$HOME/pictures" XDG_PICTURES_DIR="$HOME/pictures"
XDG_PUBLICSHARE_DIR="$HOME/" XDG_PUBLICSHARE_DIR="$HOME/"
XDG_TEMPLATES_DIR="$HOME/" XDG_TEMPLATES_DIR="$HOME/"

View file

@ -0,0 +1,4 @@
-- turn on a nice table view if we have it
if require("core.util").is_available("csvview") then
require("csvview").enable()
end

View file

@ -0,0 +1,4 @@
-- turn on a nice table view if we have it
if require("core.util").is_available("csvview") then
require("csvview").enable()
end

View file

@ -16,6 +16,7 @@
"conform.nvim": { "branch": "master", "commit": "a6f5bdb78caa305496357d17e962bbc4c0b392e2" }, "conform.nvim": { "branch": "master", "commit": "a6f5bdb78caa305496357d17e962bbc4c0b392e2" },
"copilot-lualine": { "branch": "main", "commit": "6bc29ba1fcf8f0f9ba1f0eacec2f178d9be49333" }, "copilot-lualine": { "branch": "main", "commit": "6bc29ba1fcf8f0f9ba1f0eacec2f178d9be49333" },
"copilot.lua": { "branch": "master", "commit": "c1bb86abbed1a52a11ab3944ef00c8410520543d" }, "copilot.lua": { "branch": "master", "commit": "c1bb86abbed1a52a11ab3944ef00c8410520543d" },
"csvview.nvim": { "branch": "main", "commit": "a4c45eadb03a462a80dd1a545d0f9cb636b73664" },
"dial.nvim": { "branch": "master", "commit": "2c7e2750372918f072a20f3cf754d845e143d7c9" }, "dial.nvim": { "branch": "master", "commit": "2c7e2750372918f072a20f3cf754d845e143d7c9" },
"dressing.nvim": { "branch": "master", "commit": "3a45525bb182730fe462325c99395529308f431e" }, "dressing.nvim": { "branch": "master", "commit": "3a45525bb182730fe462325c99395529308f431e" },
"fidget.nvim": { "branch": "main", "commit": "b61e8af9b8b68ee0ec7da5fb7a8c203aae854f2e" }, "fidget.nvim": { "branch": "main", "commit": "b61e8af9b8b68ee0ec7da5fb7a8c203aae854f2e" },
@ -73,6 +74,7 @@
"nvim-lint": { "branch": "master", "commit": "f126af5345c7472e9a0cdbe1d1a29209be72c4c4" }, "nvim-lint": { "branch": "master", "commit": "f126af5345c7472e9a0cdbe1d1a29209be72c4c4" },
"nvim-lspconfig": { "branch": "master", "commit": "77d3fdfb3554632c7a3b101ded643d422de7626f" }, "nvim-lspconfig": { "branch": "master", "commit": "77d3fdfb3554632c7a3b101ded643d422de7626f" },
"nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" }, "nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" },
"nvim-spider": { "branch": "main", "commit": "fed9f683db005e6eb676e11a615b0e249a21142e" },
"nvim-surround": { "branch": "main", "commit": "8dd9150ca7eae5683660ea20cec86edcd5ca4046" }, "nvim-surround": { "branch": "main", "commit": "8dd9150ca7eae5683660ea20cec86edcd5ca4046" },
"nvim-toggleterm.lua": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" }, "nvim-toggleterm.lua": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" },
"nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" }, "nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" },

View file

@ -43,44 +43,6 @@ return {
}, },
}, },
}, },
-- jump between letters with improved fFtT quicksearch, mimics sneak
{
"folke/flash.nvim",
event = "VeryLazy",
opts = {
modes = {
search = {
enabled = false,
},
},
},
keys = {
{
"s",
mode = { "n", "x" },
function()
require("flash").jump()
end,
desc = "Flash",
},
{
"S",
mode = { "n", "x", "o" },
function()
require("flash").treesitter()
end,
desc = "Flash Treesitter",
},
{
"r",
mode = "o",
function()
require("flash").remote()
end,
desc = "Remote Flash",
},
},
},
-- generic tool installer; automatic external dependency mgmt for neovim -- generic tool installer; automatic external dependency mgmt for neovim
-- used in my config for LSPs, formatters and linters -- used in my config for LSPs, formatters and linters
@ -100,8 +62,6 @@ return {
{ "<leader>vm", ":Mason<cr>", desc = "Mason" }, { "<leader>vm", ":Mason<cr>", desc = "Mason" },
}, },
}, },
-- personal dict improvements for git sync
{ "micarmst/vim-spellsync", event = "VeryLazy" },
{ {
"folke/which-key.nvim", "folke/which-key.nvim",
event = "CursorHold", event = "CursorHold",

View file

@ -1,4 +1,24 @@
return { return {
{
-- pretty table-view and movement for CSV-like files
"hat0uma/csvview.nvim",
opts = {
view = {
display_mode = "border",
spacing = 1,
},
keymaps = {
jump_next_field_end = { "<S-l>", mode = { "n", "v" } },
jump_prev_field_end = { "<S-h>", mode = { "n", "v" } },
jump_next_row = { "<S-j>", mode = { "n", "v" } },
jump_prev_row = { "<S-k>", mode = { "n", "v" } },
textobject_field_inner = { "if", mode = { "o", "x" } },
textobject_field_outer = { "af", mode = { "o", "x" } },
},
},
cmd = { "CsvViewEnable", "CsvViewDisable", "CsvViewToggle" },
ft = { "csv", "tsv", "dsv", "psv", "ssv", "scsv" },
},
{ {
"jmbuhr/otter.nvim", "jmbuhr/otter.nvim",
config = function() config = function()

View file

@ -2,6 +2,64 @@ return {
-- surround things with other things using ys/cs/ds -- surround things with other things using ys/cs/ds
{ "kylechui/nvim-surround", config = true, event = { "CursorHold", "InsertEnter" } }, { "kylechui/nvim-surround", config = true, event = { "CursorHold", "InsertEnter" } },
-- more intelligent w/e/b key jumps including CamelCase, snake_case words and
-- ignoring some punctuation
{
"chrisgrieser/nvim-spider",
keys = {
{ "w", "<cmd>lua require('spider').motion('w')<CR>", mode = { "n", "o", "x" } },
{ "e", "<cmd>lua require('spider').motion('e')<CR>", mode = { "n", "o", "x" } },
{ "b", "<cmd>lua require('spider').motion('b')<CR>", mode = { "n", "o", "x" } },
},
},
-- jump between letters with improved fFtT quicksearch, mimics sneak
{
"folke/flash.nvim",
event = "VeryLazy",
opts = {
modes = {
search = {
enabled = false,
},
},
},
keys = {
{
"s",
mode = { "n", "x" },
function()
require("flash").jump()
end,
desc = "Flash",
},
{
"S",
mode = { "n", "x" },
function()
require("flash").jump({
pattern = vim.fn.expand("<cword>"),
})
end,
desc = "Flash",
},
{
"r",
mode = "o",
function()
require("flash").remote()
end,
desc = "Remote Flash",
},
{
"R",
mode = { "n", "x", "o" },
function()
require("flash").treesitter_search()
end,
desc = "Flash Treesitter",
},
},
},
-- extend the ^x / ^a possibilities to dates, hex, alphabets, markdown headers -- extend the ^x / ^a possibilities to dates, hex, alphabets, markdown headers
-- REMAPPED TO C-X / C-S for decrement/increment -- REMAPPED TO C-X / C-S for decrement/increment
{ {

View file

@ -340,6 +340,8 @@ local prose_plugs = {
dependencies = { "nvim-treesitter/nvim-treesitter" }, dependencies = { "nvim-treesitter/nvim-treesitter" },
event = { "BufEnter *.mdx" }, -- since the plug itself defines mdx ft event = { "BufEnter *.mdx" }, -- since the plug itself defines mdx ft
}, },
-- personal dict improvements for git sync
{ "micarmst/vim-spellsync", event = "VeryLazy" },
} }
return prose_plugs return prose_plugs

View file

@ -1,3 +0,0 @@
# yaml-language-server: $schema=https://carapace.sh/schemas/command.json
name: cat
run: "[bat]"

View file

@ -26,9 +26,9 @@ test "$XDG_DOCUMENTS_DIR" || export XDG_DOCUMENTS_DIR="$HOME/documents"
test "$XDG_DOWNLOAD_DIR" || export XDG_DOWNLOAD_DIR="$HOME/downloads" test "$XDG_DOWNLOAD_DIR" || export XDG_DOWNLOAD_DIR="$HOME/downloads"
export XDG_MEDIA_DIR="$HOME/media" export XDG_MEDIA_DIR="$HOME/media"
export XDG_MUSIC_DIR="$XDG_MEDIA_DIR/audio/music" export XDG_MUSIC_DIR="$XDG_MEDIA_DIR/music"
export XDG_PICTURES_DIR="$HOME/pictures" export XDG_PICTURES_DIR="$HOME/pictures"
export XDG_VIDEOS_DIR="$HOME/videos" export XDG_VIDEOS_DIR="$XDG_MEDIA_DIR/videos"
## Non-Standard additions ## Non-Standard additions
# non-standard, is added to path to enable execution of any files herein # non-standard, is added to path to enable execution of any files herein

View file

@ -28,8 +28,6 @@ alias ls='ls --color=auto'
eval "$(starship init bash)" eval "$(starship init bash)"
eval "$(zoxide init bash)" eval "$(zoxide init bash)"
export CARAPACE_BRIDGES='zsh,fish,bash,inshellisense' # optional
source <(carapace _carapace)
set -o vi set -o vi
stty time 0 stty time 0

View file

@ -39,8 +39,6 @@ starship init nu | save -f ($nu.data-dir | path join "vendor/autoload/starship.n
atuin init nu | save -f ($nu.data-dir | path join "vendor/autoload/atuin.nu") atuin init nu | save -f ($nu.data-dir | path join "vendor/autoload/atuin.nu")
# load zoxide bookmarks # load zoxide bookmarks
zoxide init nushell | save -f ($nu.data-dir | path join "vendor/autoload/zoxide.nu") zoxide init nushell | save -f ($nu.data-dir | path join "vendor/autoload/zoxide.nu")
# load carapace completions
source ~/.cache/carapace/init.nu
# keybinds # keybinds
$env.config.keybindings = [ $env.config.keybindings = [

View file

@ -1,23 +0,0 @@
# env.nu
#
# Installed by:
# version = "0.102.0"
#
# Previously, environment variables were typically configured in `env.nu`.
# In general, most configuration can and should be performed in `config.nu`
# or one of the autoload directories.
#
# This file is generated for backwards compatibility for now.
# It is loaded before config.nu and login.nu
#
# See https://www.nushell.sh/book/configuration.html
#
# Also see `help config env` for more options.
#
# You can remove these comments if you want or leave
# them for future reference.
## create carapace completions
$env.CARAPACE_BRIDGES = 'zsh,fish,bash,inshellisense' # optional
mkdir ~/.cache/carapace
carapace _carapace nushell | save --force ~/.cache/carapace/init.nu

View file

@ -140,11 +140,6 @@ TRANSIENT_PROMPT_RPROMPT='$(starship prompt --right --terminal-width="$COLUMNS"
TRANSIENT_PROMPT_TRANSIENT_PROMPT='$(starship module character)' TRANSIENT_PROMPT_TRANSIENT_PROMPT='$(starship module character)'
eval "$(zoxide init zsh)" eval "$(zoxide init zsh)"
eval "$(atuin init zsh)" eval "$(atuin init zsh)"
export CARAPACE_BRIDGES='zsh,fish,bash,inshellisense' # optional
source <(carapace _carapace)
# make fzf-tab compatible with carapace
# see <https://github.com/carapace-sh/carapace-bin/issues/2819#issuecomment-3092307945>
zstyle ':fzf-tab:*' query-string ''
# Speed up autocomplete, force prefix mapping # Speed up autocomplete, force prefix mapping
zstyle ':completion:*' accept-exact '*(N)' zstyle ':completion:*' accept-exact '*(N)'

View file

@ -58,7 +58,8 @@ def --wrapped jloof [search: string, ...flags] {
alias jlfw = jj log -r "wip()" # Find 'WIP:'-prefixed changes alias jlfw = jj log -r "wip()" # Find 'WIP:'-prefixed changes
alias jlfp = jj log -r "private()" # Find 'PRIVATE:'-prefixed changes alias jlfp = jj log -r "private()" # Find 'PRIVATE:'-prefixed changes
alias jh = jj log -r 'ancestors(heads(all()), 3)' alias jlh = jj log -r 'heads(all())'
alias JLH = jj log -r 'ancestors(heads(all()), 3)'
alias jrb = jj rebase alias jrb = jj rebase

View file

@ -70,7 +70,8 @@ alias jlfw='jj log -r "wip()"'
alias jlfp='jj log -r "private()"' alias jlfp='jj log -r "private()"'
# show branches (i.e. head commits) w a couple previous commits # show branches (i.e. head commits) w a couple previous commits
alias jh="jj log -r 'ancestors(heads(all()), 3)'" alias jlh="jj log -r 'heads(all())'"
alias JLH="jj log -r 'ancestors(heads(all()), 3)'"
alias jrb="jj rebase" alias jrb="jj rebase"