Live data from Hacker News

Life is too short for a slow terminal

mijndertstuij.nl

51–60 of 98 posts

Re: Life is too short for a slow terminal

#51
The gem in this post is Pure, which I haven't heard of until now. I also have my prompt show the git status, and for large repos `git status` can take 10+ seconds to load and cache.

I had no idea that you could do that asynchronously, and then have ZSH update the already printed prompt with the status later! That blows my mind!

Re: Life is too short for a slow terminal

#52
post #51

The gem in this post is Pure, which I haven't heard of until now. I also have my prompt show the git status, and for large repos `git status` can take 10+ seconds to load and cache. I had no idea that you could do that asynchronously, and then have ZSH update the already printed prompt with the status later! That blows my mind!

If you like that, you should check out my project https://beachcomber.sh . Its about time I take it from dogfooding to beta users if you want to give it a go.

Re: Life is too short for a slow terminal

#53

Speaking of slow, what I absolutely cannot comprehend is why ghostty is so popular. Despite being written in Zig it is very slow and a total CPU and memory hog. Just sitting there idle it’s pulling a constant 40% of my CPU? No thanks!

WezTerm is great too and, AFAICT, is everything Ghostty wants to be. Kitty is also very good, although WezTerm edges it out for having an integrated muxer. I can't understand Ghostty either except as some kind of trendy memetic thing, the $GME of the TTY world.

Yup. For a while I was switching between all three to see which I liked most, and I always end up coming back to Wezterm. The only issue I’ve encountered is that releases on various package managers are routinely broken, but building from source solved that.

Re: Life is too short for a slow terminal

#54

I'm surprised people are still using nvm, considering it's impact on shell startup time. I can't recommend switching to mise highly enough: https://mise.en.dev/

How often do you launch a fresh terminal though? I start mine with a script to have favourite tabs ready at boot and then generally not much afterwards.

Re: Life is too short for a slow terminal

#55
post #54

I'm surprised people are still using nvm, considering it's impact on shell startup time. I can't recommend switching to mise highly enough: https://mise.en.dev/

How often do you launch a fresh terminal though? I start mine with a script to have favourite tabs ready at boot and then generally not much afterwards.

For every query and commands. I don’t use a DE, so pretty much everything is cli based. I use xterm and it’s bound to mod4+Return for me.

Re: Life is too short for a slow terminal

#56

Speaking of slow, what I absolutely cannot comprehend is why ghostty is so popular. Despite being written in Zig it is very slow and a total CPU and memory hog. Just sitting there idle it’s pulling a constant 40% of my CPU? No thanks!

I'm the creator of Ghostty. This isn't right. It should idle at 0 to 1%, as supported by sibling comments. If you can collect more details about your system please open a discussion on the main Ghostty repo. Same with memory.

In terms of speed, same thing: if you can provide some kind of objectively measurable thing, we can look into it. Everything we've measured so far firmly places Ghostty in the "fast" camp (with friends such as Kitty).

We're sometimes faster, sometimes slower, but in any case not noticeably so. You wouldn't pick Ghostty vs Kitty for example for performance, it'd be something else. But you would pick Ghostty over say... iTerm2 for performance (but you may pick iTerm2 for features, its extremely feature rich!).

Re: Life is too short for a slow terminal

#57

Am I the weird one? I usually have 3/4 terminals open at a time and rarely open new ones. Terminal startup speed is a non-issue for me. The only thing I demand to be fast on my terminal is grep reverse search (ctrl+r) and of course typing a character. But if your terminal can't keep up with your typing speed there is something deeply wrong with it.

I open and close terminals _constantly_, but I'm usually pretty weird in my workflow, so no comment on your first question.

I run a scrolling WM and have settled into a habit of opening terminals when I need them, then closing them right after. I'll open a terminal, git pull, close it. Etc. I also use a terminal that launches cold in 10-20 ms, so it's not like a pay a price for it.

This is actually what I thought this post was about! But then I saw the Ghostty reference, which, in my experience, is not very fast to launch at all. I got it opening new windows quickly by running the main process as a systemd service, but Foot launches way faster without all that fuss, and allows you to go the daemon route if you want it _even_ faster.

EDIT: Just want to clarify, no shade on Ghostty. That project is cross platform and uses the 100% defensible decision to use the full GTK stack on linux. Foot is Linux AND Wayland only, and uses that very restrictive environment to optimize the hell out of startup and general performance.

Re: Life is too short for a slow terminal

#58
post #54

I'm surprised people are still using nvm, considering it's impact on shell startup time. I can't recommend switching to mise highly enough: https://mise.en.dev/

How often do you launch a fresh terminal though? I start mine with a script to have favourite tabs ready at boot and then generally not much afterwards.

Constantly. I think we've used the excuse of "well, what if you just launch it less often?" enough to excuse bad performance defaults, especially when alternative solutions fix the issue with very few trade-offs.

Re: Life is too short for a slow terminal

#59
post #57

Am I the weird one? I usually have 3/4 terminals open at a time and rarely open new ones. Terminal startup speed is a non-issue for me. The only thing I demand to be fast on my terminal is grep reverse search (ctrl+r) and of course typing a character. But if your terminal can't keep up with your typing speed there is something deeply wrong with it.

I open and close terminals _constantly_, but I'm usually pretty weird in my workflow, so no comment on your first question. I run a scrolling WM and have settled into a habit of opening terminals when I need them, then closing them right after. I'll open a terminal, git pull, close it. Etc. I also use a terminal that launches cold in 10-20 ms, so it's not like a pay a price for it. This is actually what I thought thi…

I constantly open and close terminals too. Maybe I'm doing a quick lazygit check on cwd. Maybe I'm opening up an ephemeral claude/codex session for a couple questions about why a test failed. Or quickly editing a file with vim. Or remembering where I put that file with yazi or fzf. -- I don't even know, but all of it is contingent on it being fast to open a new terminal in cwd.

So much so that I vibe-coded my own terminal emulator for vertical tabs on macOS (using libghostty for the terminals) that is faster and less weird than iTerm.

Re: Life is too short for a slow terminal

#60
post #54

I'm surprised people are still using nvm, considering it's impact on shell startup time. I can't recommend switching to mise highly enough: https://mise.en.dev/

How often do you launch a fresh terminal though? I start mine with a script to have favourite tabs ready at boot and then generally not much afterwards.

Maybe once a minute, though it's bursty so more like 4 times every 4 minutes, but I still didn't notice the nvm slowdown
Post reply on HN