permission denied for composer in /usr/local/bin/(/usr/local/bin/中的作曲家权限被拒绝)
问题描述
我遵循了 https://getcomposer.org/doc/00-intro.md#globally<上的文档/a> 在 arch linux 上全局安装 composer.当我执行 composer self-update
时,我收到此消息:
I followed the documentation on https://getcomposer.org/doc/00-intro.md#globally to install composer globally on arch linux. When I do composer self-update
, I get this message:
[ErrorException]
rename(/home/hannes/.composer/cache/composer-temp.phar,/usr/local/bin/composer): Permission denied
/usr/local/bin/
中的权限(我改成777了,没用):
The permissions in /usr/local/bin/
(I changed them to 777, but it did not help):
-rwxrwxrwx 1 hannes users 1104202 30. Mai 18:07 composer
在我的主目录中,我这样做了:
In my home directory I did this:
sudo chmod -R 777 .composer/
在/etc/php/php.ini
中,open_basedir
看起来是这样的:
In /etc/php/php.ini
, the open_basedir
looks so:
open_basedir = /srv/http/:/home/:/tmp/:/usr/share/pear/:/usr/share/webapps/:/usr/local/bin/
我也尝试过 sudo composer self-update
但效果不佳,而且可能不是正确的方法.(?).我还能尝试做些什么来使这项工作发挥作用?
I also tried sudo composer self-update
but it did not work as well and is possibly not the right way. (?). What else could I try to make this work?
推荐答案
现在,arch linux 中有一个对我有用的 composer 包:
Now, there is a package for composer in arch linux which works for me:
sudo pacman -S composer
这篇关于/usr/local/bin/中的作曲家权限被拒绝的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:/usr/local/bin/中的作曲家权限被拒绝
基础教程推荐
- Doctrine 2 - 在多对多关系中记录更改 2022-01-01
- 在 CakePHP 2.0 中使用 Html Helper 时未定义的变量 2021-01-01
- HTTP 与 FTP 上传 2021-01-01
- 使用 PDO 转义列名 2021-01-01
- 在 yii2 中迁移时出现异常“找不到驱动程序" 2022-01-01
- 如何在 Symfony 和 Doctrine 中实现多对多和一对多? 2022-01-01
- phpmyadmin 错误“#1062 - 密钥 1 的重复条目‘1’" 2022-01-01
- PHP 守护进程/worker 环境 2022-01-01
- 找不到类“AppHttpControllersDB",我也无法使用新模型 2022-01-01
- 如何在 XAMPP 上启用 mysqli? 2021-01-01