aboutsummaryrefslogtreecommitdiffstats
path: root/src/_node
diff options
context:
space:
mode:
authorShohei YOSHIDA <syohex@gmail.com>2024-04-25 11:48:47 +0900
committerShohei YOSHIDA <syohex@gmail.com>2024-04-25 12:56:56 +0900
commita46f3ffca2fd1ef542db7fdcdebdc3045b6d1778 (patch)
tree7b030df0ab82b6a90463902c337341a3325e6305 /src/_node
parentMerge pull request #1080 from hydrargyrum/rdfind (diff)
downloadzsh-completions-a46f3ffca2fd1ef542db7fdcdebdc3045b6d1778.tar
zsh-completions-a46f3ffca2fd1ef542db7fdcdebdc3045b6d1778.tar.gz
zsh-completions-a46f3ffca2fd1ef542db7fdcdebdc3045b6d1778.tar.bz2
zsh-completions-a46f3ffca2fd1ef542db7fdcdebdc3045b6d1778.tar.lz
zsh-completions-a46f3ffca2fd1ef542db7fdcdebdc3045b6d1778.tar.xz
zsh-completions-a46f3ffca2fd1ef542db7fdcdebdc3045b6d1778.tar.zst
zsh-completions-a46f3ffca2fd1ef542db7fdcdebdc3045b6d1778.zip
Update node completion to version v22.0.0
Diffstat (limited to 'src/_node')
-rw-r--r--src/_node14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/_node b/src/_node
index 8cd0d7f..883602a 100644
--- a/src/_node
+++ b/src/_node
@@ -28,7 +28,7 @@
# Description
# -----------
#
-# Completion script for Node.js v21.3.0 (https://nodejs.org)
+# Completion script for Node.js v22.0.0 (https://nodejs.org)
#
# ------------------------------------------------------------------------------
# Authors
@@ -61,6 +61,14 @@ _node_args() {
_node_files
}
+_node_scripts() {
+ local -a scripts=()
+ if (( $+commands[jq] )) && [[ -e package.json ]]; then
+ scripts=(${(@f)"$(jq -r '.scripts | keys[]' package.json | sed 's/:/\\:/g')"})
+ fi
+ _describe 'scripts' scripts
+}
+
local curcontext="$curcontext" state line ret=1
typeset -A opt_args
@@ -145,21 +153,25 @@ _arguments -C \
'--redirect-warnings=[write warnings to file instead of stderr]: :_files' \
'--report-compact[output compact single-line JSON]' \
'--report-directory=[custom report path]: :_files -/' \
+ '--report-exclude-network[exclude network interface diagnostics(default: false)]' \
'--report-filename=[custom report file name]: :_files' \
'--report-on-fatalerror[generate diagnostic report on fatal (internal) errors]' \
'--report-on-signal=[generate diagnostic report upon receiving signals]' \
'--report-signal=[causes diagnostic report to be produced on provided signal]:signals:_signals -s' \
'--report-uncaught-exception[generate diagnostic report on uncaught exceptions]' \
+ '--run=[run a script specified in package.json]:script:_node_scripts' \
'--secure-heap=[total size of the OpenSSL secure heap]: :number' \
'--secure-heap-min=[minimum allocation size from the OpenSSL secure heap]' \
'--snapshot-blob=[path to the snapshot blob that is used to restore the application state]:snapshot:_files' \
'--test[launch test runner on startup]' \
'--test-concurrency=[specify test runner concurrency]:concurrency' \
+ '--test-force-exit[force test runner to exit upon completion]' \
'--test-name-pattern=[run tests whose name matches this regular expression]:pattern' \
'--test-only[run tests with "only" option set]' \
'*--test-reporter=[report test output using the given reporter]:reporter:(tap spec dot)' \
'*--test-reporter-destination=[report given reporter to the given destination]:destination:_files' \
'--test-shard=[run test at specific shard]:shard' \
+ '--test-timeout=[specify test runner timeout]' \
'--throw-deprecation[throw an exception on deprecations]' \
'--title=[the process title to use on startup]:process title' \
'--tls-cipher-list=[use an alternative default TLS cipher list]:cipher list string' \