"particle update-cli --help" panics
Description
When command particle update-cli --help is executed, it panics instead of showing a help message.
Steps to reproduce
Run particle update-cli --help from VSCode terminal.
Expected result
Help message and a list of arguments for update-cli command.
Actual result
Updating Particle CLI to ()... panic: Get .gz: unsupported protocol scheme ""
goroutine 7 [running]:
main.updateCLI(0xc04200e0c0, 0x6)
/home/monkbroc/Programming/go/src/github.com/particle-iot/particle-cli-wrapper/update.go:118 +0x75c
main.Update.func1(0xc04200e0c0, 0x6, 0xc04201a2a0)
/home/monkbroc/Programming/go/src/github.com/particle-iot/particle-cli-wrapper/update.go:56 +0x41
created by main.Update
/home/monkbroc/Programming/go/src/github.com/particle-iot/particle-cli-wrapper/update.go:54 +0xbb
Environment
Tell us about your setup:
- OS: Windows 10 Pro 1903
- Node (run
node -v): v18.11.1 - NPM (run
npm -v): 5.6.0 - Particle CLI (run
particle version): 1.47.0
@extesy ah, i see it now - thanks for the report :pray::+1:
It works on my machine:
$ particle update-cli --help
Update the Particle CLI to the latest version
Usage: particle update-cli [options]
Global Options:
-v, --verbose Increases how much logging to display [count]
-q, --quiet Decreases how much logging to display [count]
- OS: Ubuntu 19.04
- Node
v12.10.0 - npm:
6.11.3 - Particle CLI:
1.47.0
Also, are you sure you are running Node.js 18.11.1?
It seems that the error points to the Manifest of particle-cli-wrapper requested here did not contain the correct values:
https://github.com/particle-iot/particle-cli-wrapper/blob/master/update.go#L112-L118
It seems that the CLI invokes the updater although the command is called with --help.
@nikeee I got version numbers by running corresponding -v commands so yes, I'm sure I'm running these specific versions. Anyways @busticated was able to replicate this bug.