Commit Graph

1529 Commits

Author SHA1 Message Date
3a821d832b kitty:get_cwd: Use the match flag for performance
Instead of requesting the full tree as a JSON and extracting the focused
window with `jq`, use `kitten-@-ls`'s `--match` flag. This further
improves the performance.

Also remove the commented code using recursive descent because it is not
up-to-date anymore.
2025-12-11 15:27:38 +01:00
b291163a80 kitty:get_cwd: Make faster by not using kitten
kitten-@-ls(1) is unfortunately a bit slow (100ms) which is noticeable
when launching new windows using `get_cwd`. Make `get_cwd` faster (down
to 25ms) by communicating directly with the socket instead of using
`kitten`.
2025-12-11 15:27:23 +01:00
2e2bad65a2 polybar: Change while read loop to an xargs pipe 2025-12-10 14:27:53 +01:00
c46b1c5ea1 i3: Add bindings to switch forward & backward
After unplugging an external monitor I sometimes still have old
workspaces that I can't access through their index.
2025-12-10 14:20:40 +01:00
5f40b97e9a i3: Workspace 0 should be 10 2025-12-10 14:19:48 +01:00
5599ce14d7 i3: Normal numeric workspaces on multi outputs
Use normal workspace numbers with the output name as workspace name, but
strip the name in polybar.

See https://github.com/polybar/polybar/pull/3230 for strip-wsnames.
2025-12-04 14:31:05 +01:00
4008bb543b vim:looks: Don't hardcode the colorscheme colors 2025-11-25 18:06:24 +01:00
d0abb14567 vim: Highlight trailing spaces in colorscheme red 2025-11-25 18:06:13 +01:00
9e18be760c vim:setts: Use the number column for the signcolumn 2025-11-25 17:27:48 +01:00
04d3d6e87f vim:plugs:nrrwrgn: Add padding to small windows 2025-11-25 17:19:34 +01:00
526a37301a vim:plugs:ctags: Don't index venv and __pycache__ 2025-11-25 17:11:14 +01:00
7dc9efc0e4 vim:gitcommit: Fold unstaged and untracked files 2025-11-25 17:09:24 +01:00
9bc8b4b93f vim:ftplug:man: Only trigger one timer
Stop an already running timer similar to how it is done already when
highlighting the selection.
2025-11-25 16:07:52 +01:00
ead724b75b vim:ftplug:man: Fix WinResized support check
The check if the WinResized event is supported was broken from the
beginning on since I used `has()` instead of `exists()`.

Fixes: 558bb0582e (man.vim: Check if WinResized is supported,
       2025-01-29)
2025-11-25 15:56:21 +01:00
1c5beed613 git🐮 Fix stderr redirection
I also swapped the printf and the redirection since I think I prefer it
this way.
2025-09-21 01:34:48 +02:00
2dd1a80036 git🐮 Fix parameter quoting
The parameter expansion outside of the single quotes (or inside, however
you want to see it) was not quoted.
2025-09-21 01:30:56 +02:00
4f2a74e546 less: Remap ^E to edit current screen in vim 2025-09-19 01:47:39 +02:00
cb1821ba33 less: Remap ^Y to copying the whole file 2025-09-19 01:44:23 +02:00
5128d15251 less: Strip all ANSI sequences, not just SGR
Kitty's shell integration uses OSC sequences to mark the prompt and
output in the scrollback buffer. When opening that in vim through less I
want these to be gone as well.
2025-09-19 01:36:54 +02:00
4f6929bcce less: Keep position when editing in vim via e/E 2025-09-18 23:19:07 +02:00
2495d835b4 kitty: Slightly decrease click_interval to 0.4
Kitty's source code makes me believe that this is always 0.5s on X11.
This decreases the delay when opening links.

Link: https://github.com/kovidgoyal/kitty/blob/3482d084aef1/glfw/x11_window.c#L2360-L2363
2025-09-18 12:56:10 +02:00
dda2ff640e kitty: Increase font size by one point to 12 2025-09-18 12:26:36 +02:00
87398bf712 vim:keys: Use getreginfo() instead of getregtype()
The result from getreginfo can be passed directly to setreg making this
a bit neater. Taken from the neovim defaults (ironically not from
v_star-default).

Link: https://github.com/neovim/neovim/blob/08847a9ea15a/runtime/lua/vim/_defaults.lua#L73-L79
2025-09-18 01:08:18 +02:00
0a5b6d0767 vim:keys: Only map v_* & v_# if they don't exist
I learned just now that neovim added mappings for these by default in
v0.8.0. But instead of checking for neovim, check for the existence of
mappings in case vim adds these in the future too.
2025-09-18 01:07:34 +02:00
5b8f54b0cb vim:keys: Fix newline and tab search for v_*
Multiline search didn't work previously when searching with v_* and tabs
were ignored when searching with v_<leader>*.
2025-09-17 23:01:11 +02:00
ef5b2911bf vim:coc: Select first item before confirming
I believe I had the problem in the past that the completion wouldn't
automatically select the first entry but simply display the menu. Thus
it would simply insert a new line when pressing return to accept it.

Unfortunately I didn't commit it back then and I can't reproduce it now.
But it doesn't not hurt so I commit it to be safe.
2025-09-17 21:55:00 +02:00
768cb4ed4a vim:keys: Add mapping for git-commit-last-msg 2025-09-17 21:46:43 +02:00
f2ce78b6b3 vim:fzf: Use location list instead of the quickfix
Since the quickfix is a global list I can't keep multiple ripgrep
searches open at once. The location list is window-local thus solving
this issue.
2025-09-17 21:44:46 +02:00
a3d2bf985c i3: Use back_and_forth instead of i3-msg+jq 2025-09-17 17:35:19 +02:00
e8c5ec93f1 i3: Re-add stacking and tabbed layout bindings
I removed these in 69d0290afd (i3: Remove bindings for stacked and
tabbed layout, 2023-04-20) since I never need them and I always forgot
how to switch back when I pressed these accidentally.

Bring these back as comments, since the comment above still mentions
these and since I can imagine a rare situation where I might want one
these and simply want to comment them in.
2025-09-17 17:30:51 +02:00
ae52ba20d2 vim: Disable 'cindent' in non-code filetypes 2025-09-17 16:49:34 +02:00
ea2867fc9f dircolors: Color pdfs like images and videos 2025-09-17 16:44:48 +02:00
7c184ed11e git🐮 Fix GIT_DIR for submodules via git alias
Git sets some environment variables when executing a shell command.
Specifically it sets GIT_DIR when called inside a submodule. This makes
git inside the subshell target the main worktree instead of the
temporary one.
2025-09-15 14:24:36 +02:00
8e8ef29b37 git🐮 Use %s to print worktree path
Don't pass the worktree path directly into the format string - just to
be safe.
2025-09-15 13:49:34 +02:00
d8859bc709 git🐮 Keep as much relative offset as possible 2025-09-15 13:49:34 +02:00
65d99c40e8 git🐮 Keep relative path offset 2025-09-15 13:49:33 +02:00
d28ef61694 git🐮 Rename temporary worktree directory
Shorten the "worktree" and place the random bytes at the end for better
sorting.
2025-09-15 13:23:01 +02:00
d5a95f9ce5 git🐮 Fix name of submodules
Previously git-checkout-worktree would use the name of the superproject
instead of the submodule for the temporary directory.
2025-09-15 13:19:28 +02:00
723899d70f git: Add empty line before include section
I want the section at the very end and this broke the alphabetic
sorting.
2025-09-12 17:06:01 +02:00
126ccb0c7a git: Fix option capitalization
Semantically this changes nothing, but the name with a capital `S` is
used by git-config(1).
2025-09-12 17:04:49 +02:00
dadf344f2b git: Explicitly set core.whitespace.tabwidth=8 2025-09-12 17:03:53 +02:00
f17cde7943 git: Show all refs as decoration in logs 2025-09-12 16:57:00 +02:00
a89ad407ba git: Make all graph colors bold
This looks a bit better in my opinion.
2025-09-12 16:56:05 +02:00
a26a899213 git: Make all bold colors bright
Make all bold colors (also) bright, since kitty does not render bold
colors in their bright version, but I've gotten used to how this looks.

For the graph I've gotten rid of the boldness and only switched to
bright versions since I think it makes no sense to have different line
weights for the branches (Although I apparently never noticed, so I
can't say that this was misleading in practice).
2025-09-12 16:51:36 +02:00
6db1a710c6 git: Rename zsh-autoload.sh -> external-script.sh
With the last commit 9c1e3f4679 (git:zsh-autoload: Use relative
scripts/ folder, 2025-09-12), `zsh-autoload.sh` could execute any type
of external script. Rename it to a more generic name.
2025-09-12 16:25:39 +02:00
9c1e3f4679 git:zsh-autoload: Use relative scripts/ folder
This makes it a bit more agnostic to the type of scripts being used.
2025-09-12 14:49:59 +02:00
bb7ef3769d git: Add branch-rename
Small script to rename a branch locally and on a given remote.
2025-09-12 14:35:44 +02:00
0534ec493e zsh:alias: Make sizes an anonymous function
This way one can easily redirect stderr for both commands (not just
`sort`) and specify a path. The path defaults to the current directory,
but listing each entry by globbing.
2025-09-07 21:09:11 +02:00
708daa10dc kitty: Disable cursor shell integration
It's super slow and I really don't need it. I'd prefer to have kitty
mess with my shell as little as possible.
2025-09-04 11:14:52 +02:00
6bd13a9b56 kitty: Open url with kitty_mod+f
Similar to zathura's `f` to follow links.
2025-09-04 11:14:45 +02:00