Skip to content

Instantly share code, notes, and snippets.

View Axlefublr's full-sized avatar

Axlefublr Axlefublr

View GitHub Profile

I say "god I hate kitty" a lot, but I usually can't think of examples for why on the spot.
I just encountered yet another "god I hate" about kitty, so I'm gonna write it down while it's hot to transfer why I hate this terminal emulator so much.

I wanted a certain feature: in the tab bar, usually I want tabs to just have their number displayed, and nothing else. But optionally, I should be able to add a title to an individual tab.

You might reasonably think "oh that sure sounds like a job for a plugin" and in any other app, something this specific would require a plugin, yes. Kitty, however, picks to be between a rock and a hard place.

Usually when configuring things, ideas come to mind because I already have a very vague idea of how to do it / assume it's doable.
It was the case here too: there's an option called tab_title_template that lets you define the text displayed in each individual tab in the tab bar. Aside from feeling a bit wonky ([have a look](https://sw.kovidgoyal.net/kitty/conf/index.h

You may sometimes want to set a bunch of multicursors on a lot of lines, where just holding C and letting key repeat do the job is a bit bothersome.
So you mip to select inside paragraph, and use s to set cursors how you usually would with C, but with far less keystrokes

rec.mp4

Doing this feels illegal fwiw, but it's actually super valid for this usecase, where you want to act on a certain column, rather than anything that you can regex match by text.
If you know exactly how many columns you need to match, you could also just ^.{30} or something, but I generally don't know.
Regex is really powerful in theory, really fun to learn how to use it more creatively.

Remap keys on the xkb level

  1. xev will show you output like this:
KeyRelease event, serial 36, synthetic NO, window 0x3200001,
    root 0x530, subw 0x0, time 4335057, (943,136), root:(943,694),
    state 0x0, keycode 78 (keysym 0xff14, Scroll_Lock), same_screen YES,
    XLookupString gives 0 bytes:
    XFilterEvent returns: False

What I value most in a language is functionality — what and how easily the language lets me do things.

No wonder! That's what programming is kinda for: doing cool things more easily.

And here's lua, that doesn't even have an abstraction over something as simple as .split(). Ridiculous.

Lua has a very weak standard library. You'll find yourself reimplementing functionality that you'll be flabbergasted isn't there to begin with. Sure, some of that functionality might be simple to implement, but it shouldn't be my job. Imagine doing the equivalent of implementing the print function in every new project you create. It's disheartening.

Not only is the standard library weak, but it's also not ergonomic.