Instalando o composer no ubuntu [RESOLVIDO]

1. Instalando o composer no ubuntu [RESOLVIDO]

jose flávio alves da silva almeida
flavioalves

(usa Ubuntu)

Enviado em 13/09/2015 - 09:30h


Olá galera to migrando do windows pra o ubuntu e to adorando o ubuntu mas como ainda sou noob, tenho alguns erros, esse que tive agora foi na instalação do composer. Quando executo o comando: curl -sS https://getcomposer.org/installer | php, ele me retorna esse erro.

flavio@flavio-nash:~$ curl -sS https://getcomposer.org/installer | php
O programa 'php' não está instalado no momento. Você pode instalá-lo digitando:
sudo apt-get install php5-cli

Dizendo que o programa php não está instalado, tenho que rodar esse comando de sugestão? lembro que já tenho um ambiente lamp configurado.

att,


  


2. Re: Instalando o composer no ubuntu [RESOLVIDO]

edps
edps

(usa Slackware)

Enviado em 13/09/2015 - 10:06h


Tem certeza que o PHP está instalado? na dúvida digite aí:

$ dpkg -l | grep php 


Olha meu caso aqui:

~ » curl -sS https://getcomposer.org/installer | php
#!/usr/bin/env php
All settings correct for using Composer
Downloading...

Composer successfully installed to: /home/edps/composer.phar
Use it: php composer.phar
~ » php composer.phar
______
/ ____/___ ____ ___ ____ ____ ________ _____
/ / / __ \/ __ `__ \/ __ \/ __ \/ ___/ _ \/ ___/
/ /___/ /_/ / / / / / / /_/ / /_/ (__ ) __/ /
\____/\____/_/ /_/ /_/ .___/\____/____/\___/_/
/_/
Composer version 1.0-dev (66acee7feb51d4b30e8983c703bf07ce1d06883e) 2015-09-12 22:04:37

Usage:
command [options] [arguments]

Options:
--help (-h) Display this help message
--quiet (-q) Do not output any message
--verbose (-v|vv|vvv) Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug
--version (-V) Display this application version
--ansi Force ANSI output
--no-ansi Disable ANSI output
--no-interaction (-n) Do not ask any interactive question
--profile Display timing and memory usage information
--working-dir (-d) If specified, use the given directory as working directory.

Available commands:
about Short information about Composer
archive Create an archive of this composer package
browse Opens the package's repository URL or homepage in your browser.
clear-cache Clears composer's internal package cache.
clearcache Clears composer's internal package cache.
config Set config options
create-project Create new project from a package into given directory.
depends Shows which packages depend on the given package
diagnose Diagnoses the system to identify common errors.
dump-autoload Dumps the autoloader
dumpautoload Dumps the autoloader
global Allows running commands in the global composer dir ($COMPOSER_HOME).
help Displays help for a command
home Opens the package's repository URL or homepage in your browser.
info Show information about packages
init Creates a basic composer.json file in current directory.
install Installs the project dependencies from the composer.lock file if present, or falls back on the composer.json.
licenses Show information about licenses of dependencies
list Lists commands
remove Removes a package from the require or require-dev
require Adds required packages to your composer.json and installs them
run-script Run the scripts defined in composer.json.
search Search for packages
self-update Updates composer.phar to the latest version.
selfupdate Updates composer.phar to the latest version.
show Show information about packages
status Show a list of locally modified packages
suggests Show package suggestions
update Updates your dependencies to the latest version according to composer.json, and updates the composer.lock file.
validate Validates a composer.json and composer.lock
~ »



3. Re: Instalando o composer no ubuntu [RESOLVIDO]

edps
edps

(usa Slackware)

Enviado em 13/09/2015 - 10:12h

Dependendo das versões providas pelo Ubuntu, talvez esta dica lhe sirva:

https://edpsblog.wordpress.com/2015/03/17/mysql-e-php-mais-atuais-no-debian-wheezy/

* já tem até o PHP 7 RC2!

http://packages.dotdeb.org/pool/all/p/php7.0/
https://github.com/php/php-src/releases



4. Re: Instalando o composer no ubuntu [RESOLVIDO]

Marco Aurélio
macarena

(usa Linux Mint)

Enviado em 15/09/2015 - 23:57h


Cara, eu executaria o comando sugerido. Uma coisa é ter o serviço do php rodando no apache, outra é ter o php-cli, q é um cliente do php para rodar direto do terminal. Veja q o comando php é chamado após o pipe, e vc não tem o cliente instalado.
Pode dar algum erro caso você não tenha instalado o php via repositório do ubuntu.... mas eu testaria o apt-get install php5-cli mesmo assim.


5. Re: Instalando o composer no ubuntu [RESOLVIDO]

jose flávio alves da silva almeida
flavioalves

(usa Ubuntu)

Enviado em 16/09/2015 - 20:04h


obrigado macarena. Resolvido.


6. Re: Instalando o composer no ubuntu [RESOLVIDO]

jose ramos pereira
zeramos

(usa Slackware)

Enviado em 18/11/2015 - 09:37h


Obrigado macarena, resolveu meu problema também!



  



Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts