62 lines
1.0 kB
1
# mellon - Speak, friend, and enter
2
3
Modules for [Elvish Shell](https://github.com/elves/elvish)
4
5
# Install
6
7
```elvish
8
use epm
9
epm:install &silent-if-installed=$true github.com/ejrichards/mellon
10
11
```
12
13
## NixOS
14
15
`flake.nix` supplies a NixOS module that lets you import in the same manner as `epm`
16
17
```nix
18
{
19
inputs = {
20
mellon.url = "github:ejrichards/mellon";
21
};
22
23
outputs = {
24
mellon,
25
...
26
}:
27
{
28
...
29
nixosConfigurations = {
30
modules = [
31
mellon.nixosModules.default
32
];
33
};
34
}
35
```
36
37
# Usage
38
39
```elvish
40
use github.com/ejrichards/mellon/<module>
41
```
42
43
## `fzf.elv`
44
45
Add bindings for `Ctrl-r` and `Up` to use fzf for searching history.
46
```elvish
47
if (has-external fzf) {
48
use github.com/ejrichards/mellon/fzf
49
set edit:insert:binding[Ctrl-r] = { fzf:history }
50
set edit:insert:binding[Up] = { fzf:history }
51
}
52
```
53
54
## `yazi.elv`
55
56
Add an alias `y` that will `cd` on quit.
57
```elvish
58
if (has-external yazi) {
59
use github.com/ejrichards/mellon/yazi
60
edit:add-var y~ $yazi:y~
61
}
62
```
63