按照此链接的说明安装了作曲家:https://www.digitalocean.com/community/tutorials/how-to-install-and-use-composer-on-ubuntu-16-04
进入项目仓库以运行composer install
,但它出现了
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for phpunit/php-code-coverage 4.0.8 -> satisfiable by phpunit/php-code-coverage[4.0.8].
- phpunit/php-code-coverage 4.0.8 requires ext-dom * -> the requested PHP extension dom is missing from your system.
Problem 2
- Installation request for phpunit/phpunit 5.7.20 -> satisfiable by phpunit/phpunit[5.7.20].
- phpunit/phpunit 5.7.20 requires ext-dom * -> the requested PHP extension dom is missing from your system.
To enable extensions, verify that they are enabled in your .ini files:
- /etc/php/7.2/cli/php.ini
- /etc/php/7.2/cli/conf.d/10-mysqlnd.ini
- /etc/php/7.2/cli/conf.d/10-opcache.ini
- /etc/php/7.2/cli/conf.d/10-pdo.ini
- /etc/php/7.2/cli/conf.d/20-calendar.ini
- /etc/php/7.2/cli/conf.d/20-ctype.ini
- /etc/php/7.2/cli/conf.d/20-exif.ini
- /etc/php/7.2/cli/conf.d/20-fileinfo.ini
- /etc/php/7.2/cli/conf.d/20-ftp.ini
- /etc/php/7.2/cli/conf.d/20-gettext.ini
- /etc/php/7.2/cli/conf.d/20-iconv.ini
- /etc/php/7.2/cli/conf.d/20-json.ini
- /etc/php/7.2/cli/conf.d/20-mbstring.ini
- /etc/php/7.2/cli/conf.d/20-mysqli.ini
- /etc/php/7.2/cli/conf.d/20-pdo_mysql.ini
- /etc/php/7.2/cli/conf.d/20-phar.ini
- /etc/php/7.2/cli/conf.d/20-posix.ini
- /etc/php/7.2/cli/conf.d/20-readline.ini
- /etc/php/7.2/cli/conf.d/20-shmop.ini
- /etc/php/7.2/cli/conf.d/20-sockets.ini
- /etc/php/7.2/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.2/cli/conf.d/20-sysvsem.ini
- /etc/php/7.2/cli/conf.d/20-sysvshm.ini
- /etc/php/7.2/cli/conf.d/20-tokenizer.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
我是Ubuntu的新手,并且在Windows之前没有遇到过这种情况。 这是通过Ubuntu安装composer的常见步骤吗? 我该如何解决这个问题?
答案 0 :(得分:0)
如果您使用digitalocean作为主持人,那么我的建议是与他们联系。我认为他们也有现场支持。
这是因为您使用的计划可能有一些限制或需要权限。
如果您在PC中安装,请参阅一些用于教程的博客/网站,而不是专注于任何特定的设置。