安装作曲家时遇到问题
2022-08-30 14:40:36
我正在安装具有以下凸轮的作曲家
curl -s https://getcomposer.org/installer | php
但我一直得到下面的错误消息
Zafars-MacBook-Pro:etc zafarsaleem$ curl -s https://getcomposer.org/installer | php
#!/usr/bin/env php
Some settings on your machine make Composer unable to work properly.
Make sure that you fix the issues listed below and run this script again:
The detect_unicode setting must be disabled.
Add the following to the end of your `php.ini`:
detect_unicode = Off
A php.ini file does not exist. You will have to create one.
如何安装作曲家删除上述错误?
编辑
Zafars-MacBook-Pro:etc zafarsaleem$ php --ini
Configuration File (php.ini) Path: /etc
Loaded Configuration File: (none)
Scan for additional .ini files in: (none)
Additional .ini files parsed: (none)
最新编辑
经过一些研究,我发现正在使用的文件位于.但是,当我在文件夹中检查此文件时,它不存在。 文件夹包含链接到 的文件夹。所以我添加了并将此文件重命名为.现在当我执行以下命令时php.ini
/etc/php.ini
/etc
/etc
php.ini.default
/private/etc/php.ini.default
detect_unicode = Off
/etc/php.ini.default
php.ini
curl -s https://getcomposer.org/installer | php
或
sudo curl -s https://getcomposer.org/installer | php
然后我得到以下错误
Zafars-MacBook-Pro:/ zafarsaleem$ sudo curl -s https://getcomposer.org/installer | php
#!/usr/bin/env php
All settings correct for using Composer
Downloading...
Download failed: failed to open stream: Permission denied
Downloading...
Download failed: failed to open stream: Permission denied
Downloading...
Download failed: failed to open stream: Permission denied
The download failed repeatedly, aborting.
如何在计算机上安装作曲家并消除上述问题?请帮忙