From f36a7262db4df95ef9f0eb2504ab9b86b9d770fc Mon Sep 17 00:00:00 2001 From: Klaus Hipp Date: Tue, 7 Jan 2025 19:32:16 +0100 Subject: [PATCH] Revert "Fix typo in npm completions: isntall -> install" (#11014) * Revert "Fix typo in npm completions: isntall -> install" This reverts commit f4b01bb638fe0b8060403313fdcb617a52aca047. * Add comments about typos in `npm` completions (cherry picked from commit 4def0ac616a99398db18de54bb415bcc9eb320f1) --- share/completions/npm.fish | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/share/completions/npm.fish b/share/completions/npm.fish index ecafdbb4e..c5526e462 100644 --- a/share/completions/npm.fish +++ b/share/completions/npm.fish @@ -141,7 +141,8 @@ complete -f -c npm -n '__fish_npm_using_command cache' -s h -l help -d 'Display # install-ci-test complete -f -c npm -n __fish_npm_needs_command -a 'ci clean-install' -d 'Clean install a project' complete -f -c npm -n __fish_npm_needs_command -a 'install-ci-test cit' -d 'Install a project with a clean slate and run tests' -for c in ci clean-install ic install-clean install-clean install-ci-test cit clean-install-test sit +# typos are intentional +for c in ci clean-install ic install-clean isntall-clean install-ci-test cit clean-install-test sit complete -x -c npm -n "__fish_npm_using_command $c" -l install-strategy -a 'hoisted nested shallow linked' -d 'Install strategy' complete -x -c npm -n "__fish_npm_using_command $c" -l omit -a 'dev optional peer' -d 'Omit dependency type' complete -x -c npm -n "__fish_npm_using_command $c" -l strict-peer-deps -d 'Treat conflicting peerDependencies as failure' @@ -406,7 +407,8 @@ end complete -c npm -n __fish_npm_needs_command -a 'install add i' -d 'Install a package' complete -f -c npm -n __fish_npm_needs_command -a 'install-test it' -d 'Install package(s) and run tests' complete -f -c npm -n __fish_npm_needs_command -a 'link ln' -d 'Symlink a package folder' -for c in install add i in ins inst insta instal isnt isnta isntal install install-test it link ln +# typos are intentional +for c in install add i in ins inst insta instal isnt isnta isntal isntall install-test it link ln complete -f -c npm -n "__fish_npm_using_command $c" -s S -l save -d 'Save to dependencies' complete -f -c npm -n "__fish_npm_using_command $c" -l no-save -d 'Prevents saving to dependencies' complete -f -c npm -n "__fish_npm_using_command $c" -s P -l save-prod -d 'Save to dependencies' @@ -726,4 +728,4 @@ complete -f -c npm -n '__fish_npm_using_command whoami' -a registry -d 'Check re complete -f -c npm -n '__fish_npm_using_command whoami' -s h -l help -d 'Display help' # misc -complete -f -c npm -n '__fish_seen_subcommand_from add i in ins inst insta instal isnt isnta isntal install; and not __fish_is_switch' -a "(__npm_filtered_list_packages \"$npm_install\")" +complete -f -c npm -n '__fish_seen_subcommand_from add i in ins inst insta instal isnt isnta isntal isntall; and not __fish_is_switch' -a "(__npm_filtered_list_packages \"$npm_install\")"