New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tools: add bash completion for node #20713

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
10 participants
@danbev
Member

danbev commented May 14, 2018

This commit adds a --completion-bash option to node which can be sourced to
provide bash code completion for node options.

Usage:

$ node --completion-bash > node_bash_completion
$ source node_bash_completion
$ ./node --[tab]
--abort_on_uncaught_exception  --inspect-brk-node=            --require
--check                        --inspect-brk=                 --security-reverts
--completion-bash              --inspect-port                 --stack_trace_limit
--debug                        --inspect=                     --throw-deprecation
--debug-brk                    --interactive                  --title
--debug-brk=                   --loader                       --tls-cipher-list
--debug-port                   --max_old_space_size           --trace-deprecation
--debug=                       --napi-modules                 --trace-event-categories
--eval                         --no-deprecation               --trace-event-file-pattern
--experimental-modules         --no-force-async-hooks-checks  --trace-events-enabled
--experimental-repl-await      --no-warnings                  --trace-sync-io
--experimental-vm-modules      --openssl-config               --trace-warnings
--experimental-worker          --pending-deprecation          --track-heap-objects
--expose-internals             --perf_basic_prof              --use-bundled-ca
--expose_internals             --perf_prof                    --use-openssl-ca
--help                         --preserve-symlinks            --v8-options
--icu-data-dir                 --preserve-symlinks-main       --v8-pool-size
--inspect                      --print                        --version
--inspect-brk                  --prof-process                 --zero-fill-buffers
--inspect-brk-node             --redirect-warnings
Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
@danbev

This comment has been minimized.

Show comment
Hide comment
@mscdex

This comment has been minimized.

Show comment
Hide comment
@mscdex

mscdex May 14, 2018

Contributor

Isn't that output missing some options, like --v8-options and --v8-pool-size=num?

Contributor

mscdex commented May 14, 2018

Isn't that output missing some options, like --v8-options and --v8-pool-size=num?

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev May 14, 2018

Member

Isn't that output missing some options, like --v8-options and --v8-pool-size=num?

Oh indeed, I missed that. I'll take a look. Thanks

Member

danbev commented May 14, 2018

Isn't that output missing some options, like --v8-options and --v8-pool-size=num?

Oh indeed, I missed that. I'll take a look. Thanks

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev May 14, 2018

Member

With the latest update output looks like this:

$ ./node --
--                             --no-deprecation               --trace-deprecation
--abort-on-uncaught-exception  --no-force-async-hooks-checks  --trace-event-categories
--check                        --no-warnings                  --trace-event-file-pattern
--eval                         --openssl-config=file          --trace-events-enabled
--experimental-modules         --pending-deprecation          --trace-sync-io
--experimental-repl-await      --preserve-symlinks            --trace-warnings
--experimental-vm-modules      --preserve-symlinks-main       --track-heap-objects
--help                         --print                        --use-bundled-ca
--icu-data-dir=dir             --prof                         --use-openssl-ca
--inspect-brk[=[host:]port]    --prof-process                 --v8-options
--inspect-port=[host:]port     --redirect-warnings=file       --v8-pool-size=num
--inspect[=[host:]port]        --require                      --version
--interactive                  --throw-deprecation            --zero-fill-buffers
--napi-modules                 --tls-cipher-list=val
Member

danbev commented May 14, 2018

With the latest update output looks like this:

$ ./node --
--                             --no-deprecation               --trace-deprecation
--abort-on-uncaught-exception  --no-force-async-hooks-checks  --trace-event-categories
--check                        --no-warnings                  --trace-event-file-pattern
--eval                         --openssl-config=file          --trace-events-enabled
--experimental-modules         --pending-deprecation          --trace-sync-io
--experimental-repl-await      --preserve-symlinks            --trace-warnings
--experimental-vm-modules      --preserve-symlinks-main       --track-heap-objects
--help                         --print                        --use-bundled-ca
--icu-data-dir=dir             --prof                         --use-openssl-ca
--inspect-brk[=[host:]port]    --prof-process                 --v8-options
--inspect-port=[host:]port     --redirect-warnings=file       --v8-pool-size=num
--inspect[=[host:]port]        --require                      --version
--interactive                  --throw-deprecation            --zero-fill-buffers
--napi-modules                 --tls-cipher-list=val
@addaleax

This comment has been minimized.

Show comment
Hide comment
@addaleax

addaleax May 14, 2018

Member

I know some UNIX CLI tools ship something like tool --completion baked into the executable, which provides a source-able bash script as the output. Would that make sense?

Member

addaleax commented May 14, 2018

I know some UNIX CLI tools ship something like tool --completion baked into the executable, which provides a source-able bash script as the output. Would that make sense?

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev May 14, 2018

Member

Would that make sense?

That sounds interesting for sure!

Member

danbev commented May 14, 2018

Would that make sense?

That sounds interesting for sure!

@BridgeAR

This comment has been minimized.

Show comment
Hide comment
@BridgeAR

BridgeAR May 29, 2018

Member

@danbev is this actually work in progress or ready to review?

Member

BridgeAR commented May 29, 2018

@danbev is this actually work in progress or ready to review?

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev May 30, 2018

Member

@danbev is this actually work in progress or ready to review?

I'll mark it as in progress and follow up later this week. Thanks

Member

danbev commented May 30, 2018

@danbev is this actually work in progress or ready to review?

I'll mark it as in progress and follow up later this week. Thanks

@danbev danbev added the in progress label May 30, 2018

@maclover7

This comment has been minimized.

Show comment
Hide comment
@maclover7
Member

maclover7 commented Aug 11, 2018

ping @danbev

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev Aug 15, 2018

Member

I know some UNIX CLI tools ship something like tool --completion baked into the executable, which provides a source-able bash script as the output.

Sorry about the delay on this. Just to clarify, your suggestion is that we provide an option to node which returns the source-able bash script? Something like:

$ node --completion
Member

danbev commented Aug 15, 2018

I know some UNIX CLI tools ship something like tool --completion baked into the executable, which provides a source-able bash script as the output.

Sorry about the delay on this. Just to clarify, your suggestion is that we provide an option to node which returns the source-able bash script? Something like:

$ node --completion

@danbev danbev removed the in progress label Aug 16, 2018

@danbev

This comment has been minimized.

Show comment
Hide comment
Member

danbev commented Aug 20, 2018

@danbev

This comment has been minimized.

Show comment
Hide comment
Member

danbev commented Aug 24, 2018

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev Aug 24, 2018

Member

@addaleax Would you be able to take a look at this once more when you get a chance, and see if this is what you had in mind regarding your suggestion of using the --completion option?

Member

danbev commented Aug 24, 2018

@addaleax Would you be able to take a look at this once more when you get a chance, and see if this is what you had in mind regarding your suggestion of using the --completion option?

Show outdated Hide outdated src/node.cc Outdated
@refack

This comment has been minimized.

Show comment
Hide comment
@refack

refack Aug 24, 2018

Member

I'm tending toward -0 on this, as is. Since the real "magic" is baked into the --help logic, this seems like a too specific change for a specific target (IIUC just bash), that could be replaced with a simple independant snippet:

_node_complete()
{
  local cur_word options
  cur_word="${COMP_WORDS[COMP_CWORD]}"
  options="`$1 --help`"
  if [[ "${cur_word}" == -* ]] ; then
    COMPREPLY=( $(compgen -W '${options}' -- "${cur_word}") )
    return 0
  else
    COMPREPLY=( $(compgen -f "${cur_word}") )
    return 0
  fi
}
complete -F _node_complete node node_g
Member

refack commented Aug 24, 2018

I'm tending toward -0 on this, as is. Since the real "magic" is baked into the --help logic, this seems like a too specific change for a specific target (IIUC just bash), that could be replaced with a simple independant snippet:

_node_complete()
{
  local cur_word options
  cur_word="${COMP_WORDS[COMP_CWORD]}"
  options="`$1 --help`"
  if [[ "${cur_word}" == -* ]] ; then
    COMPREPLY=( $(compgen -W '${options}' -- "${cur_word}") )
    return 0
  else
    COMPREPLY=( $(compgen -f "${cur_word}") )
    return 0
  fi
}
complete -F _node_complete node node_g
Show outdated Hide outdated src/node.cc Outdated
@addaleax

This comment has been minimized.

Show comment
Hide comment
@addaleax

addaleax Aug 24, 2018

Member

@danbev Just to make sure, have you seen #22490? I don’t know whether this would help make this more robust or not, but it seems like it might.

Member

addaleax commented Aug 24, 2018

@danbev Just to make sure, have you seen #22490? I don’t know whether this would help make this more robust or not, but it seems like it might.

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev Aug 24, 2018

Member

Just to make sure, have you seen #22490?

Thanks I was not aware of it. I'll take a look closer look at it next week. Thanks

Member

danbev commented Aug 24, 2018

Just to make sure, have you seen #22490?

Thanks I was not aware of it. I'll take a look closer look at it next week. Thanks

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev Aug 24, 2018

Member

Since the real "magic" is baked into the --help logic, this seems like a too specific change for a specific target (IIUC just bash), that could be replaced with a simple independant snippet:

This was what the original commit did, but was changed after the suggestion in #20713 (comment).

Member

danbev commented Aug 24, 2018

Since the real "magic" is baked into the --help logic, this seems like a too specific change for a specific target (IIUC just bash), that could be replaced with a simple independant snippet:

This was what the original commit did, but was changed after the suggestion in #20713 (comment).

@danbev

This comment has been minimized.

Show comment
Hide comment
Member

danbev commented Sep 5, 2018

Show outdated Hide outdated doc/api/cli.md Outdated
Show resolved Hide resolved src/node.cc Outdated
@jasnell

jasnell approved these changes Sep 5, 2018

Couple of nits but otherwise LGTM

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev
Member

danbev commented Sep 9, 2018

@danbev

This comment has been minimized.

Show comment
Hide comment
Member

danbev commented Sep 9, 2018

@addaleax

This comment has been minimized.

Show comment
Hide comment
Member

addaleax commented Sep 17, 2018

@joyeecheung joyeecheung referenced this pull request Sep 18, 2018

Closed

CI failures: 20180918 #16

tools: add bash completion for node
This commit adds a --completion-bash option to node which can be
sourced to provide bash code completion for node options.

Usage:
$ node --completion-bash  > node_bash_completion
$ source node_bash_completion
$ node --[tab]
@danbev

This comment has been minimized.

Show comment
Hide comment
Member

danbev commented Sep 20, 2018

@richardlau

This comment has been minimized.

Show comment
Hide comment
@richardlau

richardlau Sep 20, 2018

Member

linuxone failures were a job configuration issue that is now fixed: nodejs/build#1501

Member

richardlau commented Sep 20, 2018

linuxone failures were a job configuration issue that is now fixed: nodejs/build#1501

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev
Member

danbev commented Sep 20, 2018

@richardlau Thanks!

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev Sep 21, 2018

Member

Re-build of failing node-test-commit-linuxone was successful.

Member

danbev commented Sep 21, 2018

Re-build of failing node-test-commit-linuxone was successful.

@danbev

This comment has been minimized.

Show comment
Hide comment
@danbev

danbev Sep 21, 2018

Member

Landed in 56493bf.

Member

danbev commented Sep 21, 2018

Landed in 56493bf.

@danbev danbev closed this Sep 21, 2018

@danbev danbev deleted the danbev:node_bash_completion branch Sep 21, 2018

danbev added a commit that referenced this pull request Sep 21, 2018

tools: add bash completion for node
This commit adds a --completion-bash option to node which can be
sourced to provide bash code completion for node options.

Usage:
$ node --completion-bash  > node_bash_completion
$ source node_bash_completion
$ node --[tab]

PR-URL: #20713
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>

targos added a commit that referenced this pull request Sep 21, 2018

tools: add bash completion for node
This commit adds a --completion-bash option to node which can be
sourced to provide bash code completion for node options.

Usage:
$ node --completion-bash  > node_bash_completion
$ source node_bash_completion
$ node --[tab]

PR-URL: #20713
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>

@joyeecheung joyeecheung referenced this pull request Sep 25, 2018

Closed

CI failures: 20180925 #17

targos added a commit that referenced this pull request Oct 7, 2018

2018-10-XX, Version 10.12.0 (Current)
Notable changes:

* assert
  * The diff output is now a tiny bit improved by sorting object
    properties when inspecting the values that are compared with each
    other. #22788
* cli
  * The options parser now normalizes `_` to `-` in all multi-word
    command-line flags, e.g. `--no_warnings` has the same effect as
    `--no-warnings`. #23020
  * Added bash completion for the `node` binary. To generate a bash
    completion script, run `node --completion-bash`. The output can be
    saved to a file which can be sourced to enable completion.
    #20713
* crypto
  * Added support for PEM-level encryption.
    #23151
  * Added an API asymmetric key pair generation. The new methods
    `crypto.generateKeyPair` and `crypto.generateKeyPairSync` can be
    used to generate public and private key pairs. The API supports
    RSA, DSA and EC and a variety of key encodings (both PEM and DER).
    #22660
* fs
  * Added a `recursive` option to `fs.mkdir` and `fs.mkdirSync`. If
    this option is set to true, non-existing parent folders will be
    automatically created. #21875
* http2
  * Added a `'ping'` event to `Http2Session` that is emitted whenever a
    non-ack `PING` is received.
    #23009
  * Added support for the `ORIGIN` frame.
    #22956
* module
  * Added `module.createRequireFromPath(filename)`. This new method can
    be used to create a custom require function that will resolve
    modules relative to the filename path.
    #19360
* process
  * Added a `'multipleResolves'` process event that is emitted whenever
    a `Promise` is attempted to be resolved multiple times, e.g. if the
    `resolve` and `reject` functions are both called in a `Promise`
    executor. #22218
* **url**
  * Added `url.fileURLToPath(url)` and `url.pathToFileURL(path)`. These
    methods can be used to correctly convert between file: URLs and
    absolute paths. #22506
* **util**
  * Added the `sorted` option to `util.inspect()`. If set to `true`,
    all properties of an object and Set and Map entries will be sorted
    in the returned string. If set to a function, it is used as a
    compare function. #22788
  * The `util.instpect.custom` symbol is now defined in the global
    symbol registry as `Symbol.for('nodejs.util.inspect.custom')`.
    #20857
* **Windows**
  * The Windows msi installer now provides an option to automatically
    install the tools required to build native modules.
    #22645
* **Added new collaborators**:
  * digitalinfinity - Hitesh Kanwathirtha

@targos targos referenced this pull request Oct 7, 2018

Merged

Release proposal: v10.12.0 #23313

targos added a commit that referenced this pull request Oct 7, 2018

2018-10-XX, Version 10.12.0 (Current)
Notable changes:

* assert
  * The diff output is now a tiny bit improved by sorting object
    properties when inspecting the values that are compared with each
    other. #22788
* cli
  * The options parser now normalizes `_` to `-` in all multi-word
    command-line flags, e.g. `--no_warnings` has the same effect as
    `--no-warnings`. #23020
  * Added bash completion for the `node` binary. To generate a bash
    completion script, run `node --completion-bash`. The output can be
    saved to a file which can be sourced to enable completion.
    #20713
* crypto
  * Added support for PEM-level encryption.
    #23151
  * Added an API asymmetric key pair generation. The new methods
    `crypto.generateKeyPair` and `crypto.generateKeyPairSync` can be
    used to generate public and private key pairs. The API supports
    RSA, DSA and EC and a variety of key encodings (both PEM and DER).
    #22660
* fs
  * Added a `recursive` option to `fs.mkdir` and `fs.mkdirSync`. If
    this option is set to true, non-existing parent folders will be
    automatically created. #21875
* http2
  * Added a `'ping'` event to `Http2Session` that is emitted whenever a
    non-ack `PING` is received.
    #23009
  * Added support for the `ORIGIN` frame.
    #22956
* module
  * Added `module.createRequireFromPath(filename)`. This new method can
    be used to create a custom require function that will resolve
    modules relative to the filename path.
    #19360
* process
  * Added a `'multipleResolves'` process event that is emitted whenever
    a `Promise` is attempted to be resolved multiple times, e.g. if the
    `resolve` and `reject` functions are both called in a `Promise`
    executor. #22218
* **url**
  * Added `url.fileURLToPath(url)` and `url.pathToFileURL(path)`. These
    methods can be used to correctly convert between file: URLs and
    absolute paths. #22506
* **util**
  * Added the `sorted` option to `util.inspect()`. If set to `true`,
    all properties of an object and Set and Map entries will be sorted
    in the returned string. If set to a function, it is used as a
    compare function. #22788
  * The `util.instpect.custom` symbol is now defined in the global
    symbol registry as `Symbol.for('nodejs.util.inspect.custom')`.
    #20857
* **Windows**
  * The Windows msi installer now provides an option to automatically
    install the tools required to build native modules.
    #22645
* **Added new collaborators**:
  * digitalinfinity - Hitesh Kanwathirtha

PR-URL: #23313

targos added a commit that referenced this pull request Oct 10, 2018

2018-10-10, Version 10.12.0 (Current)
Notable changes:

* assert
  * The diff output is now a tiny bit improved by sorting object
    properties when inspecting the values that are compared with each
    other. #22788
* cli
  * The options parser now normalizes `_` to `-` in all multi-word
    command-line flags, e.g. `--no_warnings` has the same effect as
    `--no-warnings`. #23020
  * Added bash completion for the `node` binary. To generate a bash
    completion script, run `node --completion-bash`. The output can be
    saved to a file which can be sourced to enable completion.
    #20713
* crypto
  * Added support for PEM-level encryption.
    #23151
  * Added an API asymmetric key pair generation. The new methods
    `crypto.generateKeyPair` and `crypto.generateKeyPairSync` can be
    used to generate public and private key pairs. The API supports
    RSA, DSA and EC and a variety of key encodings (both PEM and DER).
    #22660
* fs
  * Added a `recursive` option to `fs.mkdir` and `fs.mkdirSync`. If
    this option is set to true, non-existing parent folders will be
    automatically created. #21875
* http2
  * Added a `'ping'` event to `Http2Session` that is emitted whenever a
    non-ack `PING` is received.
    #23009
  * Added support for the `ORIGIN` frame.
    #22956
  * Updated nghttp2 to 1.34.0. This adds RFC 8441 extended connect
    protocol support to allow use of WebSockets over HTTP/2.
    #23284
* module
  * Added `module.createRequireFromPath(filename)`. This new method can
    be used to create a custom require function that will resolve
    modules relative to the filename path.
    #19360
* process
  * Added a `'multipleResolves'` process event that is emitted whenever
    a `Promise` is attempted to be resolved multiple times, e.g. if the
    `resolve` and `reject` functions are both called in a `Promise`
    executor. #22218
* url
  * Added `url.fileURLToPath(url)` and `url.pathToFileURL(path)`. These
    methods can be used to correctly convert between file: URLs and
    absolute paths. #22506
* util
  * Added the `sorted` option to `util.inspect()`. If set to `true`,
    all properties of an object and Set and Map entries will be sorted
    in the returned string. If set to a function, it is used as a
    compare function. #22788
  * The `util.instpect.custom` symbol is now defined in the global
    symbol registry as `Symbol.for('nodejs.util.inspect.custom')`.
    #20857
  * Added support for `BigInt` numbers in `util.format()`.
    #22097
* V8 API
  * A number of V8 C++ APIs have been marked as deprecated since they
    have been removed in the upstream repository. Replacement APIs
    are added where necessary. #23159
* Windows
  * The Windows msi installer now provides an option to automatically
    install the tools required to build native modules.
    #22645
* Workers
  * Debugging support for Workers using the DevTools protocol has been
    implemented. #21364
  * The public `inspector` module is now enabled in Workers.
    #22769
* Added new collaborators:
  * digitalinfinity - Hitesh Kanwathirtha

PR-URL: #23313

targos added a commit that referenced this pull request Oct 10, 2018

2018-10-10, Version 10.12.0 (Current)
Notable changes:

* assert
  * The diff output is now a tiny bit improved by sorting object
    properties when inspecting the values that are compared with each
    other. #22788
* cli
  * The options parser now normalizes `_` to `-` in all multi-word
    command-line flags, e.g. `--no_warnings` has the same effect as
    `--no-warnings`. #23020
  * Added bash completion for the `node` binary. To generate a bash
    completion script, run `node --completion-bash`. The output can be
    saved to a file which can be sourced to enable completion.
    #20713
* crypto
  * Added support for PEM-level encryption.
    #23151
  * Added an API asymmetric key pair generation. The new methods
    `crypto.generateKeyPair` and `crypto.generateKeyPairSync` can be
    used to generate public and private key pairs. The API supports
    RSA, DSA and EC and a variety of key encodings (both PEM and DER).
    #22660
* fs
  * Added a `recursive` option to `fs.mkdir` and `fs.mkdirSync`. If
    this option is set to true, non-existing parent folders will be
    automatically created. #21875
* http2
  * Added a `'ping'` event to `Http2Session` that is emitted whenever a
    non-ack `PING` is received.
    #23009
  * Added support for the `ORIGIN` frame.
    #22956
  * Updated nghttp2 to 1.34.0. This adds RFC 8441 extended connect
    protocol support to allow use of WebSockets over HTTP/2.
    #23284
* module
  * Added `module.createRequireFromPath(filename)`. This new method can
    be used to create a custom require function that will resolve
    modules relative to the filename path.
    #19360
* process
  * Added a `'multipleResolves'` process event that is emitted whenever
    a `Promise` is attempted to be resolved multiple times, e.g. if the
    `resolve` and `reject` functions are both called in a `Promise`
    executor. #22218
* url
  * Added `url.fileURLToPath(url)` and `url.pathToFileURL(path)`. These
    methods can be used to correctly convert between file: URLs and
    absolute paths. #22506
* util
  * Added the `sorted` option to `util.inspect()`. If set to `true`,
    all properties of an object and Set and Map entries will be sorted
    in the returned string. If set to a function, it is used as a
    compare function. #22788
  * The `util.instpect.custom` symbol is now defined in the global
    symbol registry as `Symbol.for('nodejs.util.inspect.custom')`.
    #20857
  * Added support for `BigInt` numbers in `util.format()`.
    #22097
* V8 API
  * A number of V8 C++ APIs have been marked as deprecated since they
    have been removed in the upstream repository. Replacement APIs
    are added where necessary. #23159
* Windows
  * The Windows msi installer now provides an option to automatically
    install the tools required to build native modules.
    #22645
* Workers
  * Debugging support for Workers using the DevTools protocol has been
    implemented. #21364
  * The public `inspector` module is now enabled in Workers.
    #22769
* Added new collaborators:
  * digitalinfinity - Hitesh Kanwathirtha

PR-URL: #23313

targos added a commit that referenced this pull request Oct 10, 2018

2018-10-10, Version 10.12.0 (Current)
Notable changes:

* assert
  * The diff output is now a tiny bit improved by sorting object
    properties when inspecting the values that are compared with each
    other. #22788
* cli
  * The options parser now normalizes `_` to `-` in all multi-word
    command-line flags, e.g. `--no_warnings` has the same effect as
    `--no-warnings`. #23020
  * Added bash completion for the `node` binary. To generate a bash
    completion script, run `node --completion-bash`. The output can be
    saved to a file which can be sourced to enable completion.
    #20713
* crypto
  * Added support for PEM-level encryption.
    #23151
  * Added an API asymmetric key pair generation. The new methods
    `crypto.generateKeyPair` and `crypto.generateKeyPairSync` can be
    used to generate public and private key pairs. The API supports
    RSA, DSA and EC and a variety of key encodings (both PEM and DER).
    #22660
* fs
  * Added a `recursive` option to `fs.mkdir` and `fs.mkdirSync`. If
    this option is set to true, non-existing parent folders will be
    automatically created. #21875
* http2
  * Added a `'ping'` event to `Http2Session` that is emitted whenever a
    non-ack `PING` is received.
    #23009
  * Added support for the `ORIGIN` frame.
    #22956
  * Updated nghttp2 to 1.34.0. This adds RFC 8441 extended connect
    protocol support to allow use of WebSockets over HTTP/2.
    #23284
* module
  * Added `module.createRequireFromPath(filename)`. This new method can
    be used to create a custom require function that will resolve
    modules relative to the filename path.
    #19360
* process
  * Added a `'multipleResolves'` process event that is emitted whenever
    a `Promise` is attempted to be resolved multiple times, e.g. if the
    `resolve` and `reject` functions are both called in a `Promise`
    executor. #22218
* url
  * Added `url.fileURLToPath(url)` and `url.pathToFileURL(path)`. These
    methods can be used to correctly convert between file: URLs and
    absolute paths. #22506
* util
  * Added the `sorted` option to `util.inspect()`. If set to `true`,
    all properties of an object and Set and Map entries will be sorted
    in the returned string. If set to a function, it is used as a
    compare function. #22788
  * The `util.instpect.custom` symbol is now defined in the global
    symbol registry as `Symbol.for('nodejs.util.inspect.custom')`.
    #20857
  * Added support for `BigInt` numbers in `util.format()`.
    #22097
* V8 API
  * A number of V8 C++ APIs have been marked as deprecated since they
    have been removed in the upstream repository. Replacement APIs
    are added where necessary. #23159
* Windows
  * The Windows msi installer now provides an option to automatically
    install the tools required to build native modules.
    #22645
* Workers
  * Debugging support for Workers using the DevTools protocol has been
    implemented. #21364
  * The public `inspector` module is now enabled in Workers.
    #22769
* Added new collaborators:
  * digitalinfinity - Hitesh Kanwathirtha

PR-URL: #23313

jasnell added a commit that referenced this pull request Oct 17, 2018

2018-10-10, Version 10.12.0 (Current)
Notable changes:

* assert
  * The diff output is now a tiny bit improved by sorting object
    properties when inspecting the values that are compared with each
    other. #22788
* cli
  * The options parser now normalizes `_` to `-` in all multi-word
    command-line flags, e.g. `--no_warnings` has the same effect as
    `--no-warnings`. #23020
  * Added bash completion for the `node` binary. To generate a bash
    completion script, run `node --completion-bash`. The output can be
    saved to a file which can be sourced to enable completion.
    #20713
* crypto
  * Added support for PEM-level encryption.
    #23151
  * Added an API asymmetric key pair generation. The new methods
    `crypto.generateKeyPair` and `crypto.generateKeyPairSync` can be
    used to generate public and private key pairs. The API supports
    RSA, DSA and EC and a variety of key encodings (both PEM and DER).
    #22660
* fs
  * Added a `recursive` option to `fs.mkdir` and `fs.mkdirSync`. If
    this option is set to true, non-existing parent folders will be
    automatically created. #21875
* http2
  * Added a `'ping'` event to `Http2Session` that is emitted whenever a
    non-ack `PING` is received.
    #23009
  * Added support for the `ORIGIN` frame.
    #22956
  * Updated nghttp2 to 1.34.0. This adds RFC 8441 extended connect
    protocol support to allow use of WebSockets over HTTP/2.
    #23284
* module
  * Added `module.createRequireFromPath(filename)`. This new method can
    be used to create a custom require function that will resolve
    modules relative to the filename path.
    #19360
* process
  * Added a `'multipleResolves'` process event that is emitted whenever
    a `Promise` is attempted to be resolved multiple times, e.g. if the
    `resolve` and `reject` functions are both called in a `Promise`
    executor. #22218
* url
  * Added `url.fileURLToPath(url)` and `url.pathToFileURL(path)`. These
    methods can be used to correctly convert between file: URLs and
    absolute paths. #22506
* util
  * Added the `sorted` option to `util.inspect()`. If set to `true`,
    all properties of an object and Set and Map entries will be sorted
    in the returned string. If set to a function, it is used as a
    compare function. #22788
  * The `util.instpect.custom` symbol is now defined in the global
    symbol registry as `Symbol.for('nodejs.util.inspect.custom')`.
    #20857
  * Added support for `BigInt` numbers in `util.format()`.
    #22097
* V8 API
  * A number of V8 C++ APIs have been marked as deprecated since they
    have been removed in the upstream repository. Replacement APIs
    are added where necessary. #23159
* Windows
  * The Windows msi installer now provides an option to automatically
    install the tools required to build native modules.
    #22645
* Workers
  * Debugging support for Workers using the DevTools protocol has been
    implemented. #21364
  * The public `inspector` module is now enabled in Workers.
    #22769
* Added new collaborators:
  * digitalinfinity - Hitesh Kanwathirtha

PR-URL: #23313
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment