fish: add cursor abbrs
Signed-off-by: Myned <dev@bjork.tech>
This commit is contained in:
parent
0af0d6529f
commit
4c8316fccc
1 changed files with 43 additions and 24 deletions
|
@ -20,27 +20,35 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
${config.custom.username}.programs.fish = let
|
${config.custom.username}.programs.fish = let
|
||||||
any = expansion: {
|
# Expand abbreviations anywhere in the shell
|
||||||
inherit expansion;
|
#?? sudo ABBREVIATION
|
||||||
|
anywhere = expansion: {
|
||||||
|
expansion = "${expansion}%";
|
||||||
position = "anywhere";
|
position = "anywhere";
|
||||||
|
setCursor = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Set cursor position to %
|
||||||
|
#?? % | EXPANSION
|
||||||
|
cursor = expansion: {
|
||||||
|
inherit expansion;
|
||||||
|
setCursor = true;
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
shellAbbrs = {
|
shellAbbrs = {
|
||||||
# Expand abbreviations anywhere in the shell
|
"/e" = anywhere "/etc/%";
|
||||||
#?? sudo ABBREVIATION
|
"/en" = anywhere "/etc/nixos/%";
|
||||||
"/e" = any "/etc";
|
"/h" = anywhere "~/%";
|
||||||
"/en" = any "/etc/nixos";
|
"/hd" = anywhere "~/.dev/%";
|
||||||
"/h" = any "~";
|
"/n" = anywhere "/nix/%";
|
||||||
"/hd" = any "~/.dev";
|
"/nv" = anywhere "/nix/var/%";
|
||||||
"/n" = any "/nix";
|
"/nvn" = anywhere "/nix/var/nix/%";
|
||||||
"/nv" = any "/nix/var";
|
"/nvnp" = anywhere "/nix/var/nix/profiles/%";
|
||||||
"/nvn" = any "/nix/var/nix";
|
"/nvnps" = anywhere "/nix/var/nix/profiles/system/%";
|
||||||
"/nvnp" = any "/nix/var/nix/profiles";
|
"/r" = anywhere "/run/%";
|
||||||
"/nvnps" = any "/nix/var/nix/profiles/system";
|
"/rc" = anywhere "/run/current-system/%";
|
||||||
"/r" = any "/run";
|
|
||||||
"/rc" = any "/run/current-system";
|
|
||||||
|
|
||||||
reboot = "sudo systemctl reboot";
|
reboot = "sudo systemctl reboot";
|
||||||
restart = "sudo systemctl reboot";
|
restart = "sudo systemctl reboot";
|
||||||
|
@ -149,15 +157,26 @@ in {
|
||||||
k = "kitten";
|
k = "kitten";
|
||||||
ks = "kitten ssh";
|
ks = "kitten ssh";
|
||||||
|
|
||||||
n = "nixos";
|
n = "nix";
|
||||||
nb = "nixos build";
|
nb = "nix build";
|
||||||
nbb = "nixos build boot";
|
nf = "nix flake";
|
||||||
nbs = "nixos build switch";
|
nfi = "nix flake info";
|
||||||
nbt = "nixos build test";
|
nfl = "nix flake lock";
|
||||||
nd = "nixos diff";
|
nfu = "nix flake update";
|
||||||
ng = "nixos generate";
|
ngl = cursor "nix run github:nix-community/nixGL --impure -- %";
|
||||||
nl = "nixos list";
|
nr = "nix run nixpkgs#";
|
||||||
nr = "nixos repl";
|
ns = "nix shell nixpkgs#";
|
||||||
|
nt = "nix store";
|
||||||
|
|
||||||
|
no = "nixos";
|
||||||
|
nob = "nixos build";
|
||||||
|
nobb = "nixos build boot";
|
||||||
|
nobs = "nixos build switch";
|
||||||
|
nobt = "nixos build test";
|
||||||
|
nod = "nixos diff";
|
||||||
|
nog = "nixos generate";
|
||||||
|
nol = "nixos list";
|
||||||
|
nor = "nixos repl";
|
||||||
|
|
||||||
sc = "systemctl";
|
sc = "systemctl";
|
||||||
scp = "sudo systemctl poweroff";
|
scp = "sudo systemctl poweroff";
|
||||||
|
|
Loading…
Add table
Reference in a new issue