-
-
Save jcwillox/a9b480f8d180d44368e7df2eb7009207 to your computer and use it in GitHub Desktop.
Hey, just thought I would put an updated comment on. Used the default method today and worked like a charm, found the dirs and applications and added / removed them super easy. Cheers!
Forgot to update the instructions comment at the top for toolbox 2.0, but better late than never, you can just use the direct install method now.
https://gist.github.com/jcwillox/a9b480f8d180d44368e7df2eb7009207?permalink_comment_id=4037552#gistcomment-4037552
I think I need a little more context/guidance for this one. First, the installation instructions needed an explicit parameter in modern pwsh:
❌
iwr https://gist.github.com/jcwillox/a9b480f8d180d44368e7df2eb7009207/raw/toolbox-context-menu.ps1 -o toolbox-context-menu.ps1
Invoke-WebRequest: Parameter cannot be processed because the parameter name 'o' is ambiguous. Possible matches include: -OperationTimeoutSeconds -OutFile -OutVariable -OutBuffer.
👇
✅
iwr https://gist.github.com/jcwillox/a9b480f8d180d44368e7df2eb7009207/raw/toolbox-context-menu.ps1 -OutFile toolbox-context-menu.ps1
Now, how exactly do I use it?
No matter the parameters, I get an error:
pwsh> .\toolbox-context-menu.ps1 webstorm
WARNING: no channels found in 'C:\Users\josch\AppData\Local\JetBrains\Toolbox\apps\Datalore'
WARNING: no channels found in 'C:\Users\josch\AppData\Local\JetBrains\Toolbox\apps\JetBrainsGateway'
Exception: D:\projects\toolbox-context-menu.ps1:101
Line |
101 | $binPath = Join-Path $versionPath "bin"
| ~~~~~~~~~~~~
| Cannot bind argument to parameter 'Path' because it is null.
Yep thanks, the download command is broken in my terminal now too, pretty bad of them to break that in a minor update, but anyhow, I've updated the download command.
That comment provides the usage instructions too, and it looks like you're not running the correct command, for toolbox v2, you should use something like this
.\toolbox-context-menu.ps1 -AppDir "C:\Users\%USERNAME%\AppData\Local\Programs\PyCharm Professional"
Thanks! Pretty sure you just need to enable "shell scripts" in toolbox's settings and provide toolbox a location to put the shell scripts.