Skip to content
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

-g & --global are unrecognised options #1489

Closed
1 task done
RampantDespair opened this issue Jan 14, 2025 · 2 comments
Closed
1 task done

-g & --global are unrecognised options #1489

RampantDespair opened this issue Jan 14, 2025 · 2 comments

Comments

@RampantDespair
Copy link


Steps to Reproduce

.ncurc:

N/A

Dependencies:

{
  "corepack": "0.30.0",
  "npm-check-updates": "17.1.13",
  "npm": "11.0.0"
}

Steps:

  1. Installed npm-check-updates globally using npm (npm install -g npm-check-updates)
  2. Attempted to check global packages using ncu -g
  3. Received error: "unrecognised option '-g'. Use --help for further details."

Current Behavior

The command ncu -g fails with an error about unrecognized option '-g'

Expected Behavior

The command should check for updates to global packages.

Console output

Microsoft Windows [Version 10.0.19045.5247]
(c) Microsoft Corporation. All rights reserved.

C:\Windows\system32>node -v
v23.6.0

C:\Windows\system32>npm -g ls
C:\nvm4w\nodejs -> .\
+-- corepack@0.30.0
+-- npm-check-updates@17.1.13
`-- npm@11.0.0


C:\Windows\system32>ncu -g
==ERROR== unrecognised option '-g'. Use --help for further details.

C:\Windows\system32>ncu --global
==ERROR== unrecognised option '--global'. Use --help for further details.
@raineorshine
Copy link
Owner

raineorshine commented Jan 14, 2025

It's likely that you have a different ncu executable on your PATH. The unrecognized option message of npm-check-updates looks like error: unknown option '-z'.

You can confirm with the fully qualified npm-check-updates -g. Use which ncu or a similar command on your system to identify which ncu is in your PATH.

@RampantDespair
Copy link
Author

@raineorshine
Yep you are correct:

C:\Windows\system32>where ncu
C:\Program Files\NVIDIA Corporation\Nsight Compute 2024.2.0\ncu.bat
C:\nvm4w\nodejs\ncu
C:\nvm4w\nodejs\ncu.cmd

Thanks for the help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants