ubuntu - 无法在 Ubuntu 10.04 中安装最新的 phpUnit

标签 ubuntu phpunit pear

我正在尝试在 Ubuntu 10.04 中安装 PHPUnit,但我收到了这些错误消息

sudo pear install -a pear.phpunit.de/PHPUnit
Duplicate package channel://pear.phpunit.de/File_Iterator-1.3.3 found
Duplicate package channel://pear.phpunit.de/File_Iterator-1.3.2 found
install failed

我尝试重新安装 PEAR,升级它;更新了 PEAR 和 PHPUnit channel ;清除了 PEAR 的缓存,但仍然没有成功,我不断收到同样的错误。

有没有人遇到同样的问题并且知道如何解决?

谢谢。

最佳答案

是的,Dex 指出,但我想我也会把它作为答案。

尽管不确定为什么需要 sudo(摘自 edorian 的回答),这就是我所做的。

pear clear-cache
pear install phpunit/File_Iterator
pear install phpunit/Text_Template
pear install --force --alldeps pear.phpunit.de/PHPUnit

基本上,文件迭代器和文本模板是我重复的两个,所以我必须单独安装它们,这样在安装 phpunit 时就不会失败。

关于ubuntu - 无法在 Ubuntu 10.04 中安装最新的 phpUnit,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13023808/

相关文章:

regex - 仅匹配文档中的一行,然后在 Ubuntu 上使用 bash 替换该行中的数字

phpunit - 拉拉维尔 5 : PHPUnit and no code coverage driver available

PHPUnit3.6 与 Ant 替代 --log-pmd,--log-metrics?

php - 如何在 Mac OS X 10.5 Leopard 上设置 PEAR

php - Plesk - 添加 Pear

python - 由于与 GI 相关的 python 脚本中的错误,Gnome 终端未启动

apache - 为每个用户设置不同的 apache 目录权限

linux - 我无法连接到正在运行的 ubuntu ec2 实例

phpunit - Composer 更新 codeception - phpunit 不更新

Ubuntu机器上的PHP复制粘贴检测器