通过Curl问题在Windows 11上安装Laravel:模糊重定向



我正试图通过Curl安装Laravel,以便使用像这样的docker来使用Laravel Sail

curl -s https://laravel.build/example-app | bash

但是我得到这个错误

% Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
Dload  Upload   Total   Spent    Left  Speed
100   947    0   947    0     0    947      0 --:--:-- --:--:-- --:--:--  1835
: ambiguous redirect
-bash: line 2: $'r': command not found
-bash: line 35: syntax error: unexpected end of file

我为什么会得到这个以及如何修复它?

正如您在文档中所读到的,您必须在Windows终端中使用该命令行,为您的WSL2 Linux操作系统开始一个新的终端会话。

在这里你可以找到如何将Ubuntu设置为Windows终端的默认配置文件。

这对我帮助很大。

最新更新