Created
July 27, 2021 22:31
-
-
Save lotharthesavior/07ea91972bb202ed514cda0464abdc98 to your computer and use it in GitHub Desktop.
Run node where you have only docker
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function nodeBase { | |
docker run --rm -v $(pwd):/app -w /app node:13 $1 $2 $3 $4 | |
} | |
function node { | |
nodeBase node $1 $2 $3 | |
} | |
function npm { | |
nodeBase npm $1 $2 $3 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The intention is to add the function at run-node.sh in your bash profile.
Usage: