Easily turn Nushell modules into cross-shell CLI tools
library nu nushell
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Revert "fix capture of mutable variable"

This reverts commit 372c5c2b03369e5cafa4c6673aed522475fc816a.

+2 -2
+2 -2
mod.nu
··· 3 3 4 4 const template: path = path self ./template.nu 5 5 6 - let nu_lib_dir = $NU_LIB_DIRS | first 7 - 8 6 export def install [ 9 7 src: path # Module source path 10 8 prefix?: path = ~/.local # installation prefix ··· 36 34 cp -r $src $installed_mod_path 37 35 38 36 if $install_module { 37 + let nu_lib_dir = $NU_LIB_DIRS | first 39 38 if $force {rm -f ($nu_lib_dir | path join $mod_name)} 40 39 ln -s $installed_mod_path $nu_lib_dir 41 40 } ··· 67 66 rm -f $installed_bin_path 68 67 69 68 if $remove_module { 69 + let nu_lib_dir = $NU_LIB_DIRS | first 70 70 rm -f ($nu_lib_dir | path join $mod_name) 71 71 } 72 72 }