欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  后端开发

ubuntu 使用composer 安装 laravel

程序员文章站 2024-04-05 17:43:24
...
1.先安装composer

(The recommended path, not needed.)

cd /usr/local/bin

(install)

 sudo curl -s https://getcomposer.org/installer | sudo php

(Add execute permissions.)

sudo chmod a+x composer.phar

(This step is not necessary. If needed, you can use this script to update Composer.)

sudo composer.phar self-update
mv composer.phar /usr/bin/composer

要有这一步,否则不能直接使用composer命令

进入到www目录

composer create-project laravel/laravel --prefer-dist