Closed Glavin001 closed 10 years ago
See http://stackoverflow.com/a/4351548/2578205 Sample Node.js code:
// print process.argv process.argv.forEach(function (val, index, array) { console.log(index + ': ' + val); });
Sample usage: node app -p 80 Results in
node app -p 80
0: node 1: /Users/glavin/Documents/Project Dev/smucs/app 2: -p 3: 80 Express server listening on port 8080 connected to database :: node-login
See http://stackoverflow.com/a/4351548/2578205 Sample Node.js code:
Sample usage:
node app -p 80
Results in