aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--shellrc.d/alias4
-rw-r--r--shellrc.d/dev11
2 files changed, 11 insertions, 4 deletions
diff --git a/shellrc.d/alias b/shellrc.d/alias
index 5e412a3..c84c83a 100644
--- a/shellrc.d/alias
+++ b/shellrc.d/alias
@@ -33,7 +33,3 @@ fi
if command -v sdcv 2>/dev/null >&2; then
alias sdcv='sdcv -c'
fi
-
-if command -v nix 2>/dev/null >&2; then
- alias nrun='nix run .'
-fi
diff --git a/shellrc.d/dev b/shellrc.d/dev
index e66369c..04ce496 100644
--- a/shellrc.d/dev
+++ b/shellrc.d/dev
@@ -70,3 +70,14 @@ glv() {
nvim_config() (
cd ~/.config/nvim && nvim init.vim
)
+
+if command -v nix 2>/dev/null >&2; then
+ nrun() {
+ nix run . -- "$@"
+ }
+ nrun_() {
+ local package="$1"
+ shift
+ nix run ".#$package" -- "$@"
+ }
+fi