I’m using https://zimfw.sh/ to install zsh plugins – while doing so more explicitly over the kitchen sink of ohmyzsh.
a long term TERM user
➜ ~ echo $TERM
xterm-256color
Correct.
I switched to it when macOS did - though it was on my radar for a while as so many people recommended it.
I frankly gave up on all the shells thing. I got annoyed at bash some years ago and nowadays I can’t even remember why so went for ZSH. Installed OhMyZsh and a few plugins, made the setup fully reproducible and copyable to any other machine (via chezmoi
but there are many other ways) and called it a day. Ultimately gave up on plugin managers like the one @LostKobrakai mentioned because for some reason all of them were “not found” when running my daily update-everything script. Troubleshooted that for a few hours, couldn’t fix it, said “frak it” and haven’t touched my setup in like a year. There are some small tweaks like aliases and default versions of stuff in mise
but outside of that, nothing.
I heard good things about fish
but couldn’t be bothered. Might try it still.
To me the current way things fit together – OS, shell, terminal program, piping and lack of any schema in it and it’s all text, PATH, all LD_* env vars and many others – is super broken. Much longer topic however.
I totally just use zsh for similar reasons as others have said: someone told me it was better than bash about 15 years ago so I switched to it and haven’t really thought about it since. I don’t and never have used OhMyZsh but I did learn and applied a few things from reading its source (mostly around creating my own prompt). I use two zsh-specific plugins: zsh-autosuggestions and zsh-syntax-highlighting which I understand are two attractive things about Fish (and sure there is much more to Fish but I’ve never really looked into it seriously). Of course some other non-zsh specific programs like autojump (I know there are newer fancier ones but autojump has the features I need) and FZF but otherwise I do a lot in Vim, so that probably has something to do with me not feeling a lot pain around having a fancy shell. I certainly might be missing out, but ignorance is bliss!
Installed zoxide
and never had to configure it, it just works and does exactly what I want.
I’m biased in favor of Rust programs though.
Interesting you chose to write your comment in English… why is it not written in Rust?
Zoxide is one (maybe the only one) I was thinking of! It has that nifty pop-up when there are collisions but I prefer to just add weight to the one I actually want and not think about it again (although I do always forget the option for adding and subtracting weight so that is annoying, but it’s a rare occurence).
oh-my-zsh
I did it the hard way and have a 50 line config, gives me a lot more confidence if something goes weird, zsh is a complex beast
I am using oh-my-zsh precisely because I don’t have to worry about something going wrong.
It’s been super stable and I don’t remember I’ve ever had trouble with it, just install, enable plugins I like (not many) and theme and it updates itself and leaves me alone.
I only wish there was something like that for Vim.
Lazyvim for neovim, tend to favour hand crafted vim configuration.
LazyVim breaks all the time, literally once per week.
I’ve only been using LazyVim 2 weeks, was using NvChad for the two years before that. I’ll keep an eye out for the expiration date!
I’m experimenting now with Helix editor https://helix-editor.com/
Running Fish with dotfiles managed by (Nix) Home Manager.
Nix is a rabbit hole, but I can recommend https://devenv.sh, which allows for easy setup of a locked dev environment for all kinds of services and languages. For example:
{
pkgs,
lib,
config,
inputs,
...
}: {
# https://devenv.sh/packages/
packages = with pkgs; [
git
# linter and formatter for JavaScript, TypeScript, JSX, CSS and GraphQL
biome
# Nix code formatter
alejandra
# CLI image tools ("magick")
imagemagick
# CLI image optimisation
mozjpeg
pngcrush
# PostgreSQL client utilities
postgresql
# content compression (handled by Phoenix.Bakery)
brotli
zstd
# Mermaid diagram generator
mermaid-cli
];
# https://devenv.sh/languages/
languages.elixir.enable = true;
languages.javascript.enable = true;
languages.javascript.npm.enable = true;
# https://devenv.sh/services/
services.postgres = {
enable = true;
package = pkgs.postgresql_15;
initialDatabases = [{name = "myapp_dev";} {name = "myapp_test";}];
initialScript = ''
CREATE ROLE dev WITH LOGIN PASSWORD 'dev' SUPERUSER;
'';
};
# https://devenv.sh/pre-commit-hooks/
pre-commit.hooks = {
alejandra.enable = true;
biome.enable = true;
biome.files = "\\.(js|ts|tsx|css)$";
check-added-large-files = {
enable = true;
args = ["--maxkb=10240"];
};
mix-format.enable = true;
mix-format.files = "\\.(ex|exs|heex)$";
custom-mix-test = {
enable = true;
name = "mix-test";
always_run = true;
# The command to execute (mandatory):
entry = "mix test";
# Set this to false to not pass the changed files
# to the command (default: true):
pass_filenames = false;
};
};
# https://devenv.sh/scripts/
enterShell = ''
echo
elixir --version
echo -n "Node.js "
node --version
echo
echo '🌳 Type "mix devhelp" for command list.'
echo
'';
scripts.pngoptim.exec = ''
FILENAME="$1"
if [ -z "$FILENAME" ]; then
echo "Optimise PNG files for size without quality loss"
echo
echo "Usage: pngoptim <filename>"
exit 1
fi
echo saving original to $FILENAME.orig
mv "$FILENAME" "$FILENAME.orig"
pngcrush -rem allb "$FILENAME.orig" "$FILENAME"
echo before: $(wc -c < "$FILENAME.orig") bytes, after: $(wc -c < "$FILENAME") bytes
'';
scripts.jpgoptim.exec = ''
FILENAME="$1"
if [ -z "$FILENAME" ]; then
echo "Optimise JPG files for size without quality loss"
echo
echo "Usage: jpgoptim <filename>"
exit 1
fi
echo saving original to $FILENAME.orig
cp "$FILENAME" "$FILENAME.orig"
jpegtran -copy none -outfile "$FILENAME" "$FILENAME.orig"
echo before: $(wc -c < "$FILENAME.orig") bytes, after: $(wc -c < "$FILENAME") bytes
'';
scripts.to_webp.exec = ''
FILENAME="$1"
if [ -z "$FILENAME" ]; then
echo "Convert image to lossy WEBP"
echo
echo "Usage: to_webp <filename>"
exit 1
fi
magick "$FILENAME" -define webp:lossless=false -strip "$FILENAME.webp"
echo before: $(wc -c < "$FILENAME") bytes, after: $(wc -c < "$FILENAME.webp") bytes
'';
scripts.to_webp_lossless.exec = ''
FILENAME="$1"
if [ -z "$FILENAME" ]; then
echo "Convert image to lossless WEBP"
echo
echo "Usage: to_webp_lossless <filename>"
exit 1
fi
magick "$FILENAME" -define webp:lossless=true -strip "$FILENAME.webp"
echo before: $(wc -c < "$FILENAME") bytes, after: $(wc -c < "$FILENAME.webp") bytes
'';
# See full reference at https://devenv.sh/reference/options/
}
With Direnv active, when I enter the project directory, the defined Elixir version becomes available in the path and I can call devenv up
to spin up the DB.
I like it!
(To dive deeper, there is a nice full-fledged NixOS template designed for Hetzner VPS, including complete shell and NeoVim configs: GitHub - LGUG2Z/nixos-hetzner-cloud-starter: A sane, batteries-included starter template for running NixOS on Hetzner Cloud. Would not recommend to start with NixOS, though, but to install just Nix on top of your existing OS and get started with Home Manager and Devenv.)
Zsh on Linux/Mac, Powershell for when I need to use Windows. Although I like alacritty in both cases; not sure that alacritty is actually a shell–maybe just a terminal.
I love FIsh’s software design philosophy.
Fish’s design
i’m on zsh/oh-my for the above reasons.
i went zsh → fish for 6 moths → zsh. i liked Fish a lot. problem was i couldn’t run bash scripts i found online. having to remember how to convert them or what tool to use to convert them became so frustrating. i guess today AI could do it for me. how do you deal with that?