来自官方文档
我已经安装了 Docker、Git、WSL2。
跑步时
> sudo curl -L https://raw.githubusercontent.com/nhost/cli/main/get.sh | bash
错误:
sudo : the term 'sudo' is not recognized as the name of a cmdlet, function, script file, or operable program. Check
the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ sudo curl -L https://raw.githubusercontent.com/nhost/cli/main/get.sh ...
+ ~~~~
+ CategoryInfo : ObjectNotFound: (sudo:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
我在没有 sudo 的情况下运行命令,然后错误是:
Invoke-WebRequest : A parameter cannot be found that matches parameter name 'L'.
At line:1 char:6
+ curl -L https://raw.githubusercontent.com/nhost/cli/main/get.sh | bas ...
+ ~~
+ CategoryInfo : InvalidArgument: (:) [Invoke-WebRequest], ParameterBindingException
+ FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
我想尝试gsudo但它没有Nhost作为应用程序。
您是否尝试过在不同的环境中运行它?您似乎正在尝试使用 PowerShell 或 GitBash。我运行了该请求,它似乎对我有用。