nushell shenanigans

This commit is contained in:
Matt Nish-Lapidus 2025-07-01 00:00:02 -04:00
parent 7224520616
commit b2ce760a59
4 changed files with 35 additions and 24 deletions

30
flake.lock generated
View file

@ -137,11 +137,11 @@
"nixpkgs-stable": "nixpkgs-stable" "nixpkgs-stable": "nixpkgs-stable"
}, },
"locked": { "locked": {
"lastModified": 1751303444, "lastModified": 1751337127,
"narHash": "sha256-sK8xfBTztSyqWgbxzGj86ug3vSee8A61l0iwsgoNMH4=", "narHash": "sha256-mP8SC6SWFZiji6DH65PObaKUphLLCN8FoiXmVztdR5o=",
"owner": "nix-community", "owner": "nix-community",
"repo": "emacs-overlay", "repo": "emacs-overlay",
"rev": "4a0db65ba7e8499456cacec817196eaae4cd518d", "rev": "3e2b295e2dcad08449f48669a2d1ef2596b2e5d3",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -541,11 +541,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1751309344, "lastModified": 1751336185,
"narHash": "sha256-zmb01yyOXttyhJD3kRtW6Pkt1lsPbJvN3P92/GnI0tk=", "narHash": "sha256-ptnVr2x+sl7cZcTuGx/0BOE2qCAIYHTcgfA+/h60ml0=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "78fc50f1cf8e57a974ff4bfe654563fce43d6289", "rev": "96354906f58464605ff81d2f6c2ea23211cbf051",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -687,11 +687,11 @@
"xwayland-satellite-unstable": "xwayland-satellite-unstable" "xwayland-satellite-unstable": "xwayland-satellite-unstable"
}, },
"locked": { "locked": {
"lastModified": 1751275819, "lastModified": 1751335430,
"narHash": "sha256-013hN0hBpLAPS9PQhkQKb2KOUB3Y1Ef7poANHpsxbck=", "narHash": "sha256-OVP1yknJHvRK+eIy56UZsf9kUXSmwlwitPa9dZ0/HWo=",
"owner": "sodiboo", "owner": "sodiboo",
"repo": "niri-flake", "repo": "niri-flake",
"rev": "91b2083cad55e4607ebc1cf920c08daf209ad7a0", "rev": "fab3c874b28d95696225b4e575c3b6dc5d6058fe",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -1020,11 +1020,11 @@
}, },
"nixpkgs_6": { "nixpkgs_6": {
"locked": { "locked": {
"lastModified": 1751011381, "lastModified": 1751271578,
"narHash": "sha256-krGXKxvkBhnrSC/kGBmg5MyupUUT5R6IBCLEzx9jhMM=", "narHash": "sha256-P/SQmKDu06x8yv7i0s8bvnnuJYkxVGBWLWHaU+tt4YY=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "30e2e2857ba47844aa71991daa6ed1fc678bcbb7", "rev": "3016b4b15d13f3089db8a41ef937b13a9e33a8df",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -1599,11 +1599,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1751278949, "lastModified": 1751321974,
"narHash": "sha256-wjOCGMnHbTWsxWs/V7QT9ANG3T2wx+DHs4/cg5gl2dc=", "narHash": "sha256-0NtaKDtjY8Gmj++e8ZzpFkKFp6+7AcBW+Qefj4LihAk=",
"owner": "0xc000022070", "owner": "0xc000022070",
"repo": "zen-browser-flake", "repo": "zen-browser-flake",
"rev": "9d1622af7aa4aaee79eb5e5da98f045f5b69d8f0", "rev": "03b5b1e1540b03e77e22a66379c3cddc3a7197f5",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -1,3 +0,0 @@
#!/usr/bin/env fish
cat /sys/class/power_supply/AC0/online

View file

@ -1 +1,15 @@
$env.config.completions.external.completer = $fish_completer
$env.LS_COLORS = (vivid generate one-dark)
def --env doomup [...args] {
doom sync ...$args
doom gc
systemctl --user restart emacs.service
}
def --env lla [...args] {
ls -alm ...$args | select name size type mode
}

View file

@ -5,6 +5,10 @@
enable = true; enable = true;
shellAliases = { shellAliases = {
"em" = "emacsclient -n -r"; "em" = "emacsclient -n -r";
"ls" = "ls -m";
"la" = "ls -am";
"lz" = "eza -l";
"lza" = "eza -al";
"emm" = "emacsclient -nw"; "emm" = "emacsclient -nw";
"gtr" = "gtrash restore"; "gtr" = "gtrash restore";
"rmr" = "gtrash restore"; "rmr" = "gtrash restore";
@ -12,6 +16,8 @@
"lg" = "lazygit"; "lg" = "lazygit";
"cat" = "bat --plain"; "cat" = "bat --plain";
"y" = "wezterm --config-file ~/.config/wezterm/launcher.lua start --always-new-process --cwd (pwd) yazi &"; "y" = "wezterm --config-file ~/.config/wezterm/launcher.lua start --always-new-process --cwd (pwd) yazi &";
"sbcl" = "rlwrap sbcl";
"yabup" = "yabridgectl sync --prune";
}; };
# configFile.source = ./config.nu; # configFile.source = ./config.nu;
loginFile.text = '' loginFile.text = ''
@ -43,10 +49,6 @@
}; };
}; };
}; };
extraConfig = ''
$env.config.completions.external.completer = $fish_completer
'';
extraEnv = '' extraEnv = ''
let fish_completer = {|spans| let fish_completer = {|spans|
let completions = fish --command $'complete "--do-complete=($spans | str join " ")"' let completions = fish --command $'complete "--do-complete=($spans | str join " ")"'
@ -67,8 +69,6 @@
$completions $completions
} }
} }
$env.LS_COLORS = (vivid generate one-dark)
''; '';
plugins = [ pkgs.nushellPlugins.skim ]; plugins = [ pkgs.nushellPlugins.skim ];
}; };