Linux Mint上的Laravel和Composer安装

时间:2014-09-17 07:36:24

标签: php linux laravel-5

我正在使用Linux Mint机器。我希望Laravel能够安装它。

当我搜索这个时,我得到了这个命令:curl -sS https://getcomposer.org/installer | php来自" https://getcomposer.org/download/"放入终端,但它给了我这个:

The program 'php' is currently not installed. You can install it by typing:
sudo apt-get install php5-cli
The program 'curl' is currently not installed. You can install it by typing:
sudo apt-get install curl

完成sudo apt-get install curl后

libcurl3 curl
Install these packages without verification [y/N]? y
Err http://archive.ubuntu.com/ubuntu/ quantal-updates/main libcurl3 i386 7.27.0-1ubuntu1.9
  404  Not Found [IP: 91.189.91.15 80]
Err http://security.ubuntu.com/ubuntu/ quantal-security/main libcurl3 i386 7.27.0-1ubuntu1.9
  404  Not Found [IP: 91.189.91.14 80]
Err http://security.ubuntu.com/ubuntu/ quantal-security/main curl i386 7.27.0-1ubuntu1.9
  404  Not Found [IP: 91.189.91.14 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/c/curl/libcurl3_7.27.0-1ubuntu1.9_i386.deb  404  Not Found [IP: 91.189.91.14 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/c/curl/curl_7.27.0-1ubuntu1.9_i386.deb  404  Not Found [IP: 91.189.91.14 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

得到了这个没有成功安装的卷曲

我怎样才能成功安装这些东西以及Composer和Laravel?

2 个答案:

答案 0 :(得分:0)

Composer已经提示你安装这些命令的方法,你应该运行这些命令,输入你的密码,这些库应该自动安装,安装完这些库后重新运行作曲家下载。

答案 1 :(得分:0)

首先请确保您已安装最新版本的curl。

我为Laravel和Composer的全局安装的整个过程制作了一个bash文件。

  1. Download it from here
  2. 在bash文件目录中打开一个终端
  3. 运行以下命令:

    bash Laravel_Global_Installer.sh

此bash文件管理以下各项的安装:

  • 最新版本的PHP及其扩展名
  • 最新版本的Composer(全局)
  • Laravel的最新版本(全球)