ScoopInstaller / Main

📦 The default bucket for Scoop.
https://scoop.sh
The Unlicense
1.54k stars 918 forks source link

The term 'Add-Path' is not recognized as a name of a cmdlet。Installing 'go' (1.22.4) [64bit] from main bucket #5883

Open dong-lufei opened 3 weeks ago

dong-lufei commented 3 weeks ago
Updating 'go' (1.22.3 -> 1.22.4)
Downloading new version
Starting download with aria2 ...
Download: Download Results:
Download: gid   |stat|avg speed  |path/URI
Download: ======+====+===========+=======================================================
Download: bf9499|OK  |   4.7MiB/s|D:/scoop_user_apps/cache/go#1.22.4#https_dl.google.com_go_go1.22.4.windows-amd64.zip
Download: Status Legend:
Download: (OK):download completed.
Checking hash of go1.22.4.windows-amd64.zip ... ok.
Uninstalling 'go' (1.22.3)
Running uninstaller script...
INFO  Removing 'C:\Users\13697\go\bin' from PATH...
Remove-Path:
Line |
   4 |  Remove-Path "$envgopath\bin" $global
     |  ~~~~~~~~~~~
     | The term 'Remove-Path' is not recognized as a name of a cmdlet, function, script file, or executable program.
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Removing shim 'go.shim'.
Removing shim 'go.exe'.
Removing shim 'gofmt.shim'.
Removing shim 'gofmt.exe'.
Unlinking D:\scoop_user_apps\apps\go\current
Installing 'go' (1.22.4) [64bit] from main bucket
Loading go1.22.4.windows-amd64.zip from cache.
Extracting go1.22.4.windows-amd64.zip ... done.
Running installer script...
INFO  Adding 'C:\Users\13697\go\bin' to PATH...
Add-Path:
Line |
   4 |  Add-Path -Path "$envgopath\bin" -Global:$global -Force
     |  ~~~~~~~~
     | The term 'Add-Path' is not recognized as a name of a cmdlet, function, script file, or executable program.
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Linking D:\scoop_user_apps\apps\go\current => D:\scoop_user_apps\apps\go\1.22.4
Creating shim for 'go'.
Creating shim for 'gofmt'.
'go' (1.22.4) was installed successfully!
Slach commented 1 week ago

same issue

@stalomeow looks like error happens after https://github.com/ScoopInstaller/Main/pull/5820

stalomeow commented 1 week ago

same issue

@stalomeow looks like error happens after #5820

I only changed the arguments, not the command. It's actually caused by #5806.

stalomeow commented 1 week ago

Add-Path and Remove-Path were first introduced in v0.4.0.

@Slach What version of scoop are you using?

Slach commented 1 week ago

@stalomeow thanks you for suggestion it was a shovel not original scoop

after clean shovel and install scoop from scratch everything works good now

scoop config rm SCOOP_REPO
scoop config rm SCOOP_BRANCH
scoop uninstall scoop