# mellon - Speak, friend, and enter Modules for [Elvish Shell](https://github.com/elves/elvish) # Install ## epm Required until git.sr.ht is added upstream: ```elvish use epm mkdir -p $epm:managed-dir/git.sr.ht/ echo "{ \"method\": \"git\", \"protocol\": \"https\", \"levels\": \"2\" }" > $epm:managed-dir/git.sr.ht/epm-domain.cfg ``` Install module ```elvish use epm epm:install &silent-if-installed=$true git.sr.ht/~ejri/mellon ``` ## NixOS `flake.nix` supplies a NixOS module that lets you import in the same manner as `epm` Input ```nix mellon.url = "git+https://git.sr.ht/~ejri/mellon"; ``` Use module ```nix { ... nixosConfigurations = { modules = [ mellon.nixosModules.default ]; }; } ``` # Usage ```elvish use git.sr.ht/~ejri/mellon/ ``` ## `atuin.elv` Add bindings for `Ctrl-r` and `Up` to use atuin for searching history. ```elvish if (has-external atuin) { use git.sr.ht/~ejri/mellon/atuin set edit:insert:binding[Ctrl-r] = { atuin:search } set edit:insert:binding[Up] = { atuin:search-up } } ``` ## `fzf.elv` Add bindings for `Ctrl-r` and `Up` to use fzf for searching history. ```elvish if (has-external fzf) { use git.sr.ht/~ejri/mellon/fzf set edit:insert:binding[Ctrl-r] = { fzf:history } set edit:insert:binding[Up] = { fzf:history } } ``` ## `yazi.elv` Add an alias `y` that will `cd` on quit. ```elvish if (has-external yazi) { use git.sr.ht/~ejri/mellon/yazi edit:add-var y~ $yazi:y~ } ```