diff --git a/README.md b/README.md index 0fa4830..17728cf 100644 --- a/README.md +++ b/README.md @@ -80,6 +80,10 @@ ngenv clear - `-P, --proto `: Specify the protocol (default: http). - `-p, --port `: Set the port for ngrok to forward (default: 3000). +- `-s, --subdomain `: Define a custom subdomain for the ngrok URL. +- `-r, --region `: Set the region for the ngrok server (default: us). +- `-a, --auth `: Set basic authentication for the ngrok tunnel. +- `-t, --authtoken `: Set the authtoken for ngrok (overrides the default). - `-e, --env `: Define a custom path to your `.env` file. ## Examples diff --git a/ngenv b/ngenv index 21574ba..a1a5d39 100755 --- a/ngenv +++ b/ngenv @@ -6,7 +6,7 @@ const { spawn, exec } = require("child_process"); const commandLineArgs = require("command-line-args"); const ngrok = require("ngrok"); -/************************************************** Global **************************************************/ +/********************************************* Global Init *********************************************/ // Get the command line options const scriptName = path.basename(process.argv[1]); @@ -26,6 +26,7 @@ function getOptions() { // { name: "hostname", alias: "H", type: String }, { name: "subdomain", alias: "s", type: String }, // { name: "config", alias: "c", type: String, multiple: true }, + // { name: "name", alias: "n", type: String }, // Tunnel name, not used yet { name: "region", alias: "r", type: String, defaultValue: "us" }, { name: "verbose", alias: "v", type: Boolean, defaultValue: false }, { name: "help", alias: "h", type: Boolean }, @@ -194,6 +195,8 @@ switch (actionVerb) { process.exit(1); } +/******************************************* Help *******************************************/ + function rootHelp() { console.log(`Usage: ${scriptName} [run|start|stop|logs|clear] [options]`); console.log(`\nCommands:`);