From 3a1f7285c0e7c53947b35df094b486cd4b9c32c5 Mon Sep 17 00:00:00 2001 From: Pieter Hintjens Date: Sun, 14 Feb 2016 11:15:37 +0100 Subject: [PATCH 1/3] Problem: command options aren't documented Reading the code to get command options isn't a problem for anyone familiar with the tool yet it's a hurdle for beginners. Solution: document the most common options. We can extend this list over time. --- README.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/README.md b/README.md index dec739f16f..3e5ba77711 100644 --- a/README.md +++ b/README.md @@ -165,6 +165,17 @@ Commands | `list` | Lists the currently installed node development file versions | `remove` | Removes the node development header files for the given version +Command options +--------------- + +`node-gyp` accepts the following command options: + +| **Option** | **Description** +|:-------------------|:------------------------------------------------ +| `-j n`, `--jobs n` | For `build`: run parallel builds +| `--silly`, `--loglevel=silly` | Log all progress to console +| `--verbose`, `--loglevel=verbose` | Log most progress to console +| `--debug` | Make Debug build (default=Release) License ------- From 3a3b7d5799ac526eaaff54b66c57cd315a2dda8b Mon Sep 17 00:00:00 2001 From: Pieter Hintjens Date: Sun, 14 Feb 2016 11:16:35 +0100 Subject: [PATCH 2/3] Problem: no documented way to disable logging Solution: document --loglevel=silent and add --silent shortcut for consistency. (I did not see any existing regression tests for options so it's unclear to me where to add a regression test for this... sorry.) --- README.md | 1 + lib/node-gyp.js | 1 + 2 files changed, 2 insertions(+) diff --git a/README.md b/README.md index 3e5ba77711..a2cf63bd3e 100644 --- a/README.md +++ b/README.md @@ -175,6 +175,7 @@ Command options | `-j n`, `--jobs n` | For `build`: run parallel builds | `--silly`, `--loglevel=silly` | Log all progress to console | `--verbose`, `--loglevel=verbose` | Log most progress to console +| `--silent`, `--loglevel=silent` | Don't log anything | `--debug` | Make Debug build (default=Release) License diff --git a/lib/node-gyp.js b/lib/node-gyp.js index a5a3328855..3b8f5b0a1c 100644 --- a/lib/node-gyp.js +++ b/lib/node-gyp.js @@ -112,6 +112,7 @@ proto.shorthands = { , j: '--jobs' , silly: '--loglevel=silly' , verbose: '--loglevel=verbose' + , silent: '--loglevel=silent' } /** From 4d5fe8fceed32aeebce29c8e22167d887da180e3 Mon Sep 17 00:00:00 2001 From: Pieter Hintjens Date: Sun, 14 Feb 2016 11:19:00 +0100 Subject: [PATCH 3/3] Problem: --release option isn't documented It's unclear why we'd need an explicit option for this, as it's the default setting. Presumably to allow Release/Debug to be passed to node-gyp. If so, we need to document it. Solution: document this option. --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index a2cf63bd3e..44cf075f93 100644 --- a/README.md +++ b/README.md @@ -177,6 +177,7 @@ Command options | `--verbose`, `--loglevel=verbose` | Log most progress to console | `--silent`, `--loglevel=silent` | Don't log anything | `--debug` | Make Debug build (default=Release) +| `--release`, `--no-debug` | Make Release build License -------