#問題点
Composerを使ってLaravelをインストールしようとすると、[InvalidArgumentException]が吐き出されて、インストールできない。
Composer (version 1.7.2) successfully installed to: /home/vagrant/laravel_lessons/composer.phar Use it: php composer.phar [vagrant@localhost laravel_lessons]$ php -r "unlink('composer-setup.php');" [vagrant@localhost laravel_lessons]$ php composer.phar create-project --prefer-dist laravel/laravel myblog Installing laravel/laravel (v5.7.0) [InvalidArgumentException] Project directory myblog/ is not empty. create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--repository REPOSITORY] [--repository-url REPOSITORY-URL] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-vcs] [--remove-vcs] [--no-install] [--ignore-platform-reqs] [--] [<package>] [<directory>] [<version>]
【追記】
myblogを空にして再びlaravelをインストールしようと思ったら、違うエラーコードが出てきた。
[vagrant@localhost laravel_lessons]$ php composer.phar create-project --prefer-dist laravel/laravel myblog Installing laravel/laravel (v5.7.0) Failed to download laravel/laravel from dist: The zip extension and unzip command are both missing, skipping. Your command-line PHP is using multiple ini files. Run `php --ini` to show them. Now trying to download from source - Installing laravel/laravel (v5.7.0): Cloning b0651d2467 Created project in myblog > @php -r "file_exists('.env') || copy('.env.example', '.env');" Loading composer repositories with package information Updating dependencies (including require-dev) Your requirements could not be resolved to an installable set of packages. Problem 1 - laravel/framework v5.7.5 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system. - laravel/framework v5.7.4 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system. - laravel/framework v5.7.3 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system. - laravel/framework v5.7.2 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system. - laravel/framework v5.7.1 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system. - laravel/framework v5.7.0 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system. - laravel/framework 5.7.x-dev requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system. - Installation request for laravel/framework 5.7.* -> satisfiable by laravel/framework[5.7.x-dev, v5.7.0, v5.7.1, v5.7.2, v5.7.3, v5.7.4, v5.7.5]. To enable extensions, verify that they are enabled in your .ini files: - /etc/php.ini - /etc/php.d/20-bz2.ini - /etc/php.d/20-calendar.ini - /etc/php.d/20-ctype.ini - /etc/php.d/20-curl.ini - /etc/php.d/20-exif.ini - /etc/php.d/20-fileinfo.ini - /etc/php.d/20-ftp.ini - /etc/php.d/20-gettext.ini - /etc/php.d/20-iconv.ini - /etc/php.d/20-json.ini - /etc/php.d/20-phar.ini - /etc/php.d/20-sockets.ini - /etc/php.d/20-tokenizer.ini You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
どうやったらLaravelをインストールできるか教えてください

回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2018/09/22 13:20
2018/09/22 13:26