I wanted a way to display a shorter path in my terminal. So I figured I'd write it in Haskell through a Nix dev shell. The result is a program that you can hook into your shell .*rc
file to run each time it renders the prompt. Example outputs:
/some/long/path/when/home/isnt/a/parent/
-> /.../parent/
/home/some/long/path/when/home/is/a/parent/
-> ~/.../parent/
TODO:
- also display repo root if you're in a repo
- Nix + Flakes (via
github:srid/haskell-flake
) + GHC 9.4 - VSCode + HLS
- fourmolu autoformatting
- Relude as Prelude.
.hlint.yaml
is from relude
- Devshell commands are provided via just; run
just
in devshell.
- Run
nix flake update
to update all flake inputs. - Run
just fmt
in nix shell to autoformat the project. This uses treefmt. - Run
just docs
to start Hoogle with packages in your cabal file.