For future reference

I have a relatively new laptop, and have spent some time today fixing some of the rough edges in my setup. (One day I'll throw all the config files into git, or something, but not yet.) I use zsh, but only in a fairly conservative manner, to emulate/mimic bash. All searches on the subject of zsh prompts seem to produce ugly behemoths from people who have just discovered that the feature exists....

Shell startup times, part 2

Following up on Saturday's post and various other blog entries about bash. While arguing with Anton about bash being slow, I discovered that /etc/bash_completion was sourced twice when starting a shell on my laptop; once in /etc/bash.bashrc, and once in ~/.bashrc. This is Debian bug #430501 - the suggestion there is that /etc/skel/.bashrc should change to check whether /etc/bash_completion had already been included. So, that saves 0.27 seconds. tim@regulus:~$ time bash -i -c exit exit real 0m0....

Shell startup times

So, a benchmark. tim@regulus:~$ time zsh -i -c exit real 0m0.064s user 0m0.048s sys 0m0.008s tim@regulus:~$ time bash -i -c exit exit real 0m0.540s user 0m0.436s sys 0m0.100s Both shells had their respective completion systems enabled. (Without them turned on, bash actually beats zsh... but the times are small enough that it doesn't matter.) These times are with a warm disk cache - the first time through both shells were slower....

Desktop annoyances - getting a prompt

Continuing my search for the subtle things that have annoyed me for years about my desktop usage, I want to think about shell startup times. Application startup times have been done to death, I'm sure - it is one of the more obvious areas to work on when improving a desktop application. Evolution's startup time is still appalling, for instance; I count five seconds before I get a GUI, and many more before I see any email....