Questions tagged [composer-php]

Composer is an application-level package manager for the PHP programming language. It provides a standard format for managing with ease PHP-based project dependencies (libraries) and was strongly inspired by Node.js's "npm" and Ruby's "bundler". Use with the [php] tag

Presentation

Composer is an application-level package manager.

Yes, it deals with "packages" or libraries, but it manages them on a per-project basis, installing them inside your project's directory.

By default, it will never install anything globally.

Thus, it is considered a PHP-based project package manager.

Useful links

It aggregates all sorts of PHP packages that are installable with Composer.

Also, you can check your build log; it could be helpful for debugging.

  • Packanalyst: Packanalyst is a service that lets you browse packages from Packagist and shows who is using and implementing your interfaces / abstract classes/traits.
11065 questions
4
votes
1 answer

Composer create local package

In my project inside the vendor directory I created a new directory named Hello and created a new class HelloWorld.php with the namespace Hello\Test. Then in the root of Hello I created a composer.json with default meta data (author, license, desc,…
Ivan
  • 5,139
  • 11
  • 53
  • 86
4
votes
4 answers

No composer options when right click

I want to try to install laravel framework using composer. But i can't see any options 'Use composer here' when right click. But i successfully install composer when I check command line 'composer'. Is there any problem? I'm using WAMP and Windows…
PHP.Newbie
  • 195
  • 1
  • 4
  • 16
4
votes
2 answers

Laravel 5 composer wont update class not found

Whenever I do composer update or artisan cache:clear and I get the following error: [Symfony\Component\Debug\Exception\FatalThrowableError] Fatal error: Class 'Aws\Laravel\AwsServiceProvider' not found My app.php config file doesn't contain the…
Matt
  • 367
  • 5
  • 17
4
votes
2 answers

Cannot install Horde Imap Client with composer

I try to install Horde/Imap_Client, as documented here In an empty directory, I create a composer.json file with the following content { "repositories": [ { "type": "pear", "url": "http://pear.horde.org" …
benoit
  • 891
  • 12
  • 22
4
votes
1 answer

Trying to get @dev version of a commit on a branch not working

With the syntax in my composer.json of "vendor/xyz-bundle": "~2.1.0@dev" I'm trying to get the latest commit in the 2.0 branch, but it always checks out the tag 2.1.0, instead of progressing to the latest commit in the 2.0 branch. This is what is…
Flat
  • 43
  • 3
4
votes
2 answers

php 5.6.17 has no php.ini

I'm trying to install composer to get laravel working. Composer gave me the following error: Some settings on your machine make Composer unable to work properly. Make sure that you fix the issues listed below and run this script again: The…
Mr Gibbous
  • 303
  • 1
  • 4
  • 11
4
votes
2 answers

issue in composer update after pulling a yii project from git

I have just cloned and pulled a yii project from yii , I've globally required fxp/composer-asset-plugin:~1.1.1 with this command composer global require "fxp/composer-asset-plugin:~1.1.1" and also globally required fxp/composer-asset-plugin with…
TheDevWay
  • 1,363
  • 1
  • 16
  • 45
4
votes
3 answers

Composer permission denied (publickey)

I Have a private repo on BitBucket, Im trying to install on localhost using composer install, here is my composer.json file: { "repositories": [ { "type": "git", "url": "git@bitbucket.org:username/repo.git" } ] } When I run…
ray sn0w
  • 1,159
  • 3
  • 11
  • 24
4
votes
1 answer

Provisioning error

Since yesterday I have an odd error during provisioning my VM. Error: curl -sS https://getcomposer.org/installer | php returned 255 instead of one of [0] It's odd because this command works fine on the machine. It seems that only response code is…
doubleB
  • 348
  • 2
  • 11
4
votes
1 answer

composer scripts use older php version

I host more and more sites on webfaction. Great provider! I ran into some problems though which I think are Linux related. Hope someone can help. SSH command php -v defaults to an older version of php, So I created an alias in my .bash_profile:…
Mattijs
  • 43
  • 1
  • 4
4
votes
1 answer

How to autoload a new folder in Laravel 5 using composer.json?

I created a small app using Laravel 5.2. I kept all of my work inside a folder called "Modules" located in App/Modules. Now, I am trying to move out my Modules folder to the root directory "outside the App folder." So my Modules folder is now…
Junior
  • 11,602
  • 27
  • 106
  • 212
4
votes
1 answer

Working with Composer vendor files in remote server

I'm getting my feet wet with dependencies. I recently wrote a small application in PHP and used Composer to get some dependencies (mainly Slim, twig, hassankhan/config and illuminate/database). So I have the project in my local computer and…
cesarcarlos
  • 1,271
  • 1
  • 13
  • 33
4
votes
1 answer

composer install - define directory

I'm running a shell script to execute composer install command. my composer.json file is in /var/www/html Is there a way I can tell composer not to run under the current directory and to run the composer.json in /var/www/html ? This is what i've…
Asaf Nevo
  • 11,338
  • 23
  • 79
  • 154
4
votes
2 answers

Laravel 5 Class 'Intervention\Image\ImageServiceProvider' not found

Hi I have problem with Intervention Image. When I use composer update or php artisan vendor:publish --provider="Intervention\Image\ImageServiceProviderLaravel5" I have error: [Symfony\Component\Debug\Exception\FatalErrorException] Class…
Stanisław Szewczyk
  • 105
  • 1
  • 3
  • 11
4
votes
2 answers

Install library with composer without updating the version of the current libraries on composer.json

So today I tried to install bootstrap with the composer via composer.json. I added twbs/bootstrap in my require list at the composer.json file in my project map and runned the command $ composer update It was succesfully downloaded and with a few…
Giesburts
  • 6,879
  • 15
  • 48
  • 85