mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 14:49:14 +00:00
fish: make ,, (nix run) better
This commit is contained in:
parent
31958d02af
commit
8d676a2ca1
2 changed files with 10 additions and 2 deletions
10
nix/homeModules/common/fish/functions/,,.fish
Normal file
10
nix/homeModules/common/fish/functions/,,.fish
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
function ,,
|
||||
if [ (count $argv) -ne 1 ]
|
||||
echo "Must provide exactly one argument, the package to be run"
|
||||
return 1
|
||||
end
|
||||
|
||||
set cmd "nix run nixpkgs#\"$argv[1]\""
|
||||
echo "Executing `$cmd`..."
|
||||
eval $cmd
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue