Add wrapper scripts for node / yarn on NixOS.
This commit is contained in:
parent
1967637d98
commit
7671bfd4d3
4 changed files with 23 additions and 0 deletions
nix
10
nix/lib.inc.sh
Normal file
10
nix/lib.inc.sh
Normal file
|
@ -0,0 +1,10 @@
|
|||
function wrap() {
|
||||
local TOOL="$1"
|
||||
local REPO="$2"
|
||||
shift
|
||||
shift
|
||||
|
||||
SHELL_NIX="$REPO/shell.nix"
|
||||
QUOTED_ARGS="$(printf "${1+ %q}" "$@")"
|
||||
exec nix-shell "$SHELL_NIX" --pure --command "$TOOL $QUOTED_ARGS"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue