Menu
  • HOME
  • TAGS

using PayWithAmazon with symfony 2 - installed with Composer

php,symfony2,amazon,composer-php,payment

I will suggest you do follow use PayWithAmazon\Client as AmazonClient; ... $amazonClient = new AmazonClient($this->amazonCredentials); ...

How to resolve composer requirements conflicts?

composer-php,laravel-5,illuminate-container

I have solved with one alias in my composer.json file: "require": { "laravel/framework": "5.1.x-dev as 5.0.28" }, So, laravel/framework have "illuminate/filesystem": "5.1.x-dev" and barryvdh/laravel-ide-helper thinks that have "illuminate/filesystem": "5.0.28" My first approach: "require": { "laravel/framework": "5.1.*", "illuminate/filesystem": "5.1.x-dev as 5.0.28" }, it's not working because illuminate/filesystem it's used as subtree...

Laravel 5 app on Bluemix

php,laravel,composer-php,bluemix

Which version of the PHP buildpack are you using? You may want to try it with the latest community release by pushing your app with the -b https://github.com/cloudfoundry/php-buildpack option. I know that with an earlier version of the buildpack (v3.1.0), you actually needed to specify a special attribute called COMPOSER_VERSION...

Php use a class in the constructor of another class and require it with namespace

php,oop,composer-php

I'm not sure how is Your app's structure looks. But try this: namespace Acme\Instagram; require_once $root_dir.'/vendor/autoload.php'; use MetzWeb\Instagram\Instagram AS InstagramClient; class Handler { /* GOT SOME USEFUL VARS HERE */ const API_URL = 'https://api.instagram.com/v1'; /** * Initialize the library * * @param array $settings Contains our ClientId and upload dir...

Many DLLs missing when installing composer (windows)

php,windows,apache,composer-php

I've solved it myself. And I'm really stupid. Problem was that when installing PHP I uncommented all extensions in php.ini - I thought the more there is, better. So I reset that whole file and uncommented only the necessary - php_pdo_mysql.dll and php_openssl.dll. Now it works. Hope this will be...

Composer autoload psr-0 doesn't find class

php,composer-php

You are using the notation PSR-4, so you need to use PSR-4. PSR-0 does not allow for an intercessory path between any portions of the class name. If you want use it you need move src/managers/ApiManager.php in src/PicoApi/Managers/ApiManager.php then "psr-0": { "PicoApi\\": "src" } ...

using composer to require file shared by multiple sub-directories

php,json,parse.com,composer-php

Composer is not built to act as a package manager, it is a dependency manager. The difference is that a package manager installs packages in a central location for everyone to use, while a depencency manager installs locally for only one application. Composer COULD install packages into a central location...

Include libraries with Composer, NPM or Bower

php,npm,composer-php,gulp,bower

They all do pretty much the same, the difference is their default package list (NPM purely NodeJS, Composer mostly PHP, Bower purely js/css, etc.) and the language they're written in. However, they all have one limitation: They can install packages in just one location. This means that you can't install...

WP_UnitTestCase - how to configure the include_path correctly with phpunit PHAR

wordpress,phpunit,composer-php

You need to clone https://core.trac.wordpress.org/browser/trunk/tests/phpunit/includes/ instead. The one you are cloning is old and is no longer updated. You will see that that line is no longer there in the new bootstrap.php....

PHPExcel cannot load spreadsheet with formula

php,composer-php,phpexcel,import-from-excel

One problem is formulae like =IFERROR(VLOOKUP($A$1*1,'List'!A:H,P5,FALSE),"") PHPExcel doesn't fully support row or column references like 'List'!A:H or 'Master'!$A:$R It does support range references however, so 'List'!A1:H1000 or 'Master'!$A1:$R1024 would be valid EDIT However, from the stack dump, it looks like a problem in an autofilter As a "Quick and Dirty"...

Failed installation of zend-escaper with Composer

php,zend-framework,composer-php

The PHP version on the command line can be a different executable than the PHP running inside the web server. It also can use a different pho.ini configuration file. So if Composer states the PHP it is using is 5.3.5, this is correct because Composer is directly asking the PHP...

symfony and Travis build composer error

php,symfony2,composer-php

All variables, denoted by %%, are expected to be set as environment variables, which your travis build/user environment lacks.

Should the vendor folder be in source control?

php,composer-php

No, the vendor directory should be excluded, and never manually touched. A composer update / composer install will generate the class loader when you install your dependencies.

How can I use the new directory structure with Symfony >=2.7?

symfony2,composer-php

It's a bug and after some research I sent a pull request. The nature of the bug is the following: In the symfony/[email protected] they replaced PSR-0 composer autoload with PSR-4 but haven't fixed the path to SymfonyStandard directory correspondingly. This causes the "post-root-package-install": [ "SymfonyStandard\\Composer::hookRootPackageInstall" ], composer script to not...

Laravel Collection installation with Composer and Laravel 5

laravel,composer-php,laravel-collection

Actually, the error messages are clear. You are trying to install a package that has a dependency of laravel componenents with a version of 5.1, but in your composer.json file, you imply that your project works with laravel 5.0. Either change the laravelcollective/html version to 5.0.* or change and upgrade...

Unable to find remote helper for 'git+https'

git,composer-php

Most likely you referenced angular-toastr as npm type and from what I remember it needs to be referenced in composer.json with bower type: "require": { "bower-asset/angular-toastr": "dev-master" } ...

Composer: Package that extends another from a fork

git,dependencies,fork,composer-php

I managed to this fix. According to composer docs, this is not an error, it's something that happens by design due to security. From a GitHub comment: Consider this: you have a project that depends on one of my packages. I depend on a package that is critical to your...

Updating project version: Composer

git,version,composer-php

There is no need to run composer update when you update your own version number. Only run it when you want to update dependencies: In order to get the latest versions of the dependencies and to update the composer.lock file, you should use the update command. php composer.phar update This...

Capistrano Symfony Deploy Failed

php,symfony2,capistrano,composer-php

I find the problem, Problem : Normally Capistrano composer sets the SYMFONY_ENV as 'prod' but it doesn't exports the var, therefore symfony trying to call development bundles but also when composer install instruction works there is --no-dev option using with command, and it is causing the problem. In vendor/ there...

How to install eZ Platform via composer

php,composer-php,ezpublish,ezplatform

You can find full installation guide in official documentation. The only command you need is curl -s http://getcomposer.org/installer | php php -d memory_limit=-1 composer.phar create-project --no-dev ezsystems/ezplatform <directory> [<version>] cd /<directory>/ ...

Composer: unresolvable dependencies when installing Silex application

php,composer-php,silex

Two of your dependencies require different versions of pimple package: silex/silex v1.2.0 requires pimple/pimple ~1.0 dflydev/doctrine-orm-service-provider v2.0.0 requires pimple/pimple >=2.1 You can switch to latest silex or previous version of doctrine-orm-service-provider to resolve this. Look at packagist.org to see available versions with their dependencies: silex, doctrine-orm-service-provider....

Why is Symfony missing dev bundles in prod environment?

php,symfony2,composer-php

It is because symfony default env is dev, composer --no-dev only tells composer not to install dev requirements, symfony does not know about the environment. Use SYMFONY_ENV=prod environmental variable. http://symfony.com/doc/current/cookbook/deployment/tools.html#c-install-update-your-vendors E.g: $ SYMFONY_ENV=prod php composer.phar install --no-dev --optimize-autoloader...

Composer install crashing on Laravel 5 (production only)

php,laravel,composer-php,laravel-5,dev-to-production

Have you examined the raw PHP logs? It is crucial to note that Laravel's logs do not contain all of the same information that PHP's raw error logs do. When using Laravel, always check the raw PHP logs when an error occurs and the visible output and Laravel log do...

Composer Autoload Issue

php,class,include,composer-php,autoload

There were two things causing issues for me, one was the class file names and the second was a composer command that needed to be run. My class file names were in the format {classname}.class.php when they need to be in the format that PSR-0 expects which is Classname.php (uppercase...

Travis CI is not case-sensitive by default?

filesystems,phpunit,composer-php,travis-ci,case-sensitive

PHP is not case sensitive when it comes to class names. If your code declares a class named Foo, and this definition is executed, you can also instantiate any other case style, like foo or fOO. PHP will preserve the case of the occurrence that triggers the autoload (i.e. the...

Laravel + git, contributers have different enviroment

php,git,laravel,dependencies,composer-php

The problem was probably this: User checked in the project, including the vendor folder. Later vendor somehow got added to .gitignore Nobody noticed that new files were not being added to the repo and magic made sure everything still worked as it did :D...

Installing PHP Github project on localhost using composer

php,github,localhost,composer-php

The package you 'installed' is a toolbox and meant to be used inside your project. It has no index.php since that would be useless, what would it have to show? You should add it to an existing project by running composer require davechild/textstatistics from your project's root directory. Composer exists...

PHP PHARs with composer?

php,composer-php,phar

Considering that the composer.phar file itself includes a few Symfony components, as well as some other libraries written by the author, and they are all put into the .phar file for distribution (including, explicitly, a number of vendor/ sub-directories), it doesn't seem unreasonable to also include the required vendor directories...

Deploy bitbucket public repo as application dependancy through composer on Heroku

git,heroku,composer-php,bitbucket

At last, I am able to fix problem. Actually it was SSH Keys issue as mentioned by @HonzaHaering in comment. I thought it will be useful for someone to add solution here. First check do you have any SSH-Key on Heroku by: ls ~/.ssh/id_rsa If you don't have key then...

How does Composer know what MediaWiki extensions to load?

composer-php,mediawiki,semantic-mediawiki

The answer, as stated in www.mediawiki.org/wiki/Composer: Composer creates an autoloader at vendor/autoload.php, which is included by WebStart.php I verified this - WebStart.php simply does this: # Load composer's autoloader if present if ( is_readable( "$IP/vendor/autoload.php" ) ) { require_once "$IP/vendor/autoload.php"; } ...

Composer + Rocketeer + ZF2- Cannot install Rocketeer due to requirements conflict

php,zend-framework2,composer-php,rocketeer

Why doesn't it install? The installed dependencies of the Zend Skeleton use symfony/console in version 2.6.6. "anahkiasen/rocketeer" requires "illuminate/console" in a version ~4.2, which itself requires "symfony/console" in version 2.5.*. Composer cannot install the new package because the installed version 2.6.6 of symfony/console will be kept, but is incompatible to...

Laravel installation via composer

php,laravel,composer-php,laravel-5

For those that experience this problem see: https://github.com/laravel/lumen-installer/issues/2 Credit to moraleslevi "For what it's worth, removing the .composer/vendor/guzzlehttp folder and re-installing the laravel installer worked."...

“PHP Composer” compared with “Ruby Gems and Bundler”

php,ruby,gem,composer-php,bundler

1) Composer is more similar to bundler. Composer brings everything in your project, bundler brings everything to your system and "links" them in the context of your project. Bundler is working with gems in the back. 2) yes. gem install does things system-wide (or per user if you use something...

Trouble with Composer Autoloading: not loading all files

php,composer-php

After much tedious searching, I've found the error in my ways - and it's pretty silly! I have a controller named student while also having a model named student, and as such I was inadvertently trying to call a class that's technically already being called. As such, it was looking...

PHP Composer Autoloader Simple Structure

php,composer-php,autoloader,psr-4

Did you define an autoload directive? You need to add this to your composer.json file: "autoload": { "psr-4": { "controllers\\": "controllers/" } } to point the autoloader in the right direction and then run composer update from the terminal in your project directory. Now the class will load without explicitly...

drush failing with autoload.php failed to open stream

php,drupal,composer-php

I haven't seen this error before, but I think it's telling you that you have to install composer, which is now a requirement for Drush. See the installation instructions for Drush: http://docs.drush.org/en/master/install/#composer-one-drush-for-all-projects.

Composer exit batch file after finish execution

php,batch-file,composer-php

I could bet that the installer is a composer.bat Batch file! If so, execute it via call command: @echo off echo Installing laravel... call composer create-project laravel/laravel system --prefer-dist echo Laravel installing is done... Now moving files and folder... ...

Slow response from getcomposer.org breaking deployments

composer-php

Getcomposer.org should not impact your deployment, however if getcomposer.org is slow, most likely packagist.org is also affected, which hosts the package information. If you directly use the projects from Packagist, your deployments not only depend on packagist.org being up, and available, but the hosting site for the projects you depend...

Laravel 4 - Class 'Stripe' not found

laravel,composer-php

Looking at packagist, you can see the composer package stripe/stripe-php point to the following GitHub repository. Based on that repository's code and the Stripe API documentation, it doesn't look like there's a global class named Stripe defined. So when you say Stripe::setApiKey(Config::get('stripe.secret_key')); and PHP says Class 'Stripe' not found PHP...

Cross system composer package installing

composer-php

To make the installed packages usable by any system user we have to create a composer.json located in the add-on packages directory (/opt/composer) and run the “composer install” command from there. Ex: cat /opt/composer/composer.json { "require": { "squizlabs/php_codesniffer": "*", "phploc/phploc": "*", "pdepend/pdepend" : "2.1.0", "phpmd/phpmd" : "*", "nikic/php-parser" : "*",...

Can't install Composer on Ubuntu behind proxy

php,ubuntu,proxy,composer-php

I got help from some experts close by: add 3 lines to /etc/profile export http_proxy=http://[username]:[password]@[webproxy]:[port] export https_proxy=http://[username]:[password]@[webproxy]:[port] export ftp_proxy=http://[username]:[password]@[webproxy]:[port] For a similar error (apt-get update was not reaching some repositories), I edited /etc/apt/apt.conf: Acquire::http::proxy "http://[username]:[password]@[webproxy]:[port]"; Acquire::https::proxy "https://[username]:[password]@[webproxy]:[port]"; Acquire::ftp::proxy...

How to override others dependencies in composer.json

php,symfony2,composer-php,symfony-2.6

In your own composer.json, you can do this: { "require": { "h4cc/alice-fixtures-bundle": "dev/master", //Whatever version you use "fzaninotto/faker": "dev-master as 1.0" } } ...

Exclude a package from updating in composer

composer-php

If you feel the need to exclude some of your packages from being updated, I'd consider this the beginning of getting into a dependency mess. You should clean up your dependencies now before it gets worse. From my experience, the topmost reason not wanting to update a dependency is when...

Where to find composer's global packages?

php,sublimetext2,composer-php,sublimetext

You can query Composer to find where it has set the user $COMPOSER_HOME directory. composer config --list --global The '[home]' line refers to the default value of $COMPOSER_HOME. Just as a final confirmation - the 'yourname' part in the configuration, would very likely need to be updated with your own...

Presta Sitemap Bundle Install Error

php,xml,symfony2,composer-php,sitemap

Try to avoid installing branches! Their stability is always "dev", and you cannot be sure which version you are installing or updating to. "presta/sitemap-bundle" has several tagged releases according to Packagist, currently ranging from 1.0.0 to 1.4.0. Pick one of these versions (there is nothing wrong with using the latest...

How to install and use php-pushwoosh on Ubuntu 12.04 LTS linux OS with/without using composer?

php,ubuntu,push-notification,composer-php,pushwoosh

Composer is a tool for dependency management in PHP. It allows you to declare the dependent libraries your project needs and it will install them in your project for you. If you are a PHP developer by profession I really recommend getting into composer, you will love this peace...

Composer - class not found after autoloading

php,composer-php

With PSR-0 In order to use PSR-0, you need to change your structure layout to: src/ └── PicoCore ├── Objects │   └── User.php └── Tests And in your composer.json you need to add PicoCore namespace: "psr-0": { "PicoCore\\": "src" } Alternative with PSR-4 If you want to keep your current...

Unable to add Laravel package Intervention Image - Requirement could not be met

php,laravel,composer-php,laravel-5,intervention

Your problem: - Installation request for way/generators ~2.0 -> satisfiable by way/generators[2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.6.1]. - way/generators 2.6.1 requires illuminate/support ~4.0 As illuminate/support is a package included in laravel/framework, their versions have to match. In your case, you have 5.0.* for laravel/framework and ~4.0 (4.*) of...

PHP Composer: Setting dynamic variable paths in the autoload function

php,composer-php,autoload

No, "dynamic paths" are not supported. A "component" folder layout, where "src" and "tests" are inside a subfolder is definitely nice, but at the moment there is no "automatical" autoloading support for this structure. When you use one namespace "application\namespace" for your system/core/ folder, all classes are scanned (including src...

Composer Package Error

github,package,composer-php,versioning,gravatar

The syntax is wrong, see Docs for Composer require. You copied the line for composer.json directly to the command line. It's composer require "karl-ballard/gravatar:^1.0" ...

How to recover destroyed laravel project with composer

php,json,laravel-4,composer-php,alerts

Your general problem is that you are using branches instead of versions. branches have two major problems: They don't point to a distinct code that was committed once in time, but are a moving target that constantly gets updates. They inherently are of development stability, which could be an acceptable...

One shared vendor with two projects

php,symfony2,composer-php,autoload,vendor

Composer works on a per project basis. One project - one vendor folder. Not, two projects and one "shared" vendor folder. We had the "shared" vendor folder approach with PEAR long enough and it simply didn't work out. Managing different project requirements with a global vendor folder is a pain,...

composer create-project - command donot work

composer-php,packagist

You're missing a stable version of vendor/projectname. In git, a tag (without flag) is a stable version and branches are dev versions. So you have to tag a release (e.g. git tag 1.0.0).

Composer package not found in private repository

git,composer-php

Your required version is almost certainly incorrect as you have a minimum-stability of dev (which is rarely a good idea). ... "require": { "pico/pico-core": "dev-dev" //ensure the dev branch actually exists }, ... Here's a useful guide to composer stability flags: https://igor.io/2013/02/07/composer-stability-flags.html...

Installing PHP Project Dependencies with Composer

php,xampp,composer-php,nette

I think your composer PATH or shortcut/batch file is kind of broken, because it tries to read the php.exe file as a JSON file. Try to remove composer completely and start with a clean install Download and install composer using the automated installer. It sets up the PATH for you,...

How to develop PHP packages in a team using composer?

php,git,composer-php

That's what we do in huge projects consisting of several little composer components which are developed at the same time: Develop your application 'in one piece' like described in the other answer your mentioned by just keeping all components separate inside their own namespaces and directory structure. /Application -composer.json (Application...

Minimum stability issue

composer-php

In your command, you duplicate require keyword. composer.phar require neitanod/forceutf8:v1.4 require => It means you want to install 2 packages. neitanod/forceutf8:v1.4 and require. Try running composer.phar require neitanod/forceutf8 only....

Install package into custom directory Composer

path,install,package,composer-php

If you want to use the installer-paths option the package you want to be installed in a different path must require composer/installers. In your case the aheinze/cockpit package doesn't require composer/installers as you can see in its composer.json at github. Have a look at the composer documentation for custom paths...

Guzzle without composer

php,composer-php,guzzle

You shouldn't go for the manual installation of Sproutvideo, because that is more of a mess than you can think of. In fact, it won't get you around using Composer for installing Guzzle at all, as you found out. When using shared hosting (and even when using dedicated servers with...

Getting code from my forked repository

git,laravel,repository,laravel-5,composer-php

Having a look at your repository in https://github.com/Yunishawash/api-guard it looks like it doesn't have a branch called dev-fullauth. Instead there is a branch dev-bugfix. But you must not name your branch including the dev- prefix. Rename your branch at github from dev-bugfix to bugfix and then your require section would...

Deploying laravel 5 with AWS EB cli: UnexpectedValueException - Invalid version string

amazon-web-services,deployment,composer-php,laravel-5

change "nikic/php-parser": "^1.2.2" to "nikic/php-parser": "1.*",

Composer update/create-project/install - HTTP Request failed

php,composer-php

I have tried it here and i have cloned a new laravel5 project with composer. composer create-project laravel/laravel --prefer-dist Like your log mentioned you can't open the routing dependency because the given json file isn't present and you get an 404 error. So i think any of your dependencies are...

Travis-CI fails to install composer deps

php,composer-php,travis-ci

Composer is unable to install php extensions yet. It looks like you need to provide source for "ext-ssh2", see this issue. { "repositories":[ { "type":"package", "package": { "name":"bower-asset/seiyria-bootstrap-slider", "version":"3.1.0", "dist": { "url": "https://github.com/seiyria/bootstrap-slider/archive/3.1.0.zip", "type": "zip" } } } ] } ...

Behat fails runing after updating dependencies

php,composer-php,behat

I don't know what your composer.json looks like but I would suggest you to use stable versions for packages in require blocks. Try to use specific versions when possible. "require": { "hello/world": "1.2.3", "abc/cde": "~4.3.0", "php": ">=5.4.0" }, "require-dev": { "similar/to-above": "1.11" }, "require-test": { "similar/to-above": "3.2.6" }, ...

Multiple apps with composer

php,deployment,frameworks,composer-php

I implemented this by creating a specific module (let's call it SM) for each client that I just add to their instance of APP For clients with specific implementation, create a new SM (specific module), that has the following composer.json file: It's an application with a client specific module...

Composer dump-autoload gives preg_match error

php,composer-php,autoload

autoload should be moved out of require-dev: { "require-dev":{ "phpunit/phpunit":"4.5.*" }, "autoload":{ "psr-0":{ "Yii\\":"yii-1.1.14.f0fee9/" } } } You can test your composer.json file using composer validate. Your original file returned: ./composer.json is invalid, the following errors/warnings were found: require-dev.autoload : invalid value, must be a string containing a version constraint...

Load git repo with composer - autoloading issue

php,git,composer-php,autoloader

Finaly, I have found out what was the problem. composer.json file in the project I was trying to load - UPS library -was invalid. I was able to download files when I ran: composer.phar install but it looks like composer.json file was ignored. I found it out when I ran...

Error: Class 'Stripe' not found

php,composer-php,bolt-cms

You should include the composer autoload file. require_once('vendor/autoload.php'); ...

Laravel Production issue - Updating composer with Laravel 4.1.x

php,laravel,composer-php

Eventually you can install php DOM extension. Certain Linux distributions do not have this extension included in the minimum PHP package. It can usually be found in one of the "optional" php-* packages. On CentOS you should be able to just run yum install php-dom or yum install php-xml. That...

Include library without running composer dump-autoload for a Laravel 4.x project in production

php,laravel,laravel-4,dependencies,composer-php

Your DevOps people are right: You shouldn't need Composer to be run in production, on the production machine(s). You have to think about a process to deploy your application. This usually means that you have a machine that is meant to do continuous integration, so every commit triggers the execution...

Downgrade Doctrine ORm 2.5 to 2.4

php,doctrine2,composer-php

I just did a quick test and it downloads 2.4 just put this composer.json into a folder an run composer install: composer.json { "name": "test/test", "description": "test", "license": "no", "require": { "doctrine/common": "2.4.*", "doctrine/dbal": "2.4.*", "doctrine/orm": "2.4.*" }, "config": { "preferred-install": "dist" }, "minimum-stability": "stable" } As you can see...

Using Composer to Install My Own Application

php,json,composer-php

Ok I found the answer: create-project composer create-project name/package public_html --stability="dev" This will create the public_html directory and download all the dependencies. Perfect....

How to to install the ircmaxell/password-compat library via Composer

symfony2,installation,composer-php,bcrypt

There are three options if you want to install something via composer. If you are using composer.phar: php composer.phar require ircmaxell/password-compat If you did a global install and do not have the phar in that directory run this instead: composer require ircmaxell/password-compat Edit composer.json and add this in require section:...

Deploying Laravel workbench projects through composer

laravel,laravel-4,composer-php

Why you force composer to do that ?. I guess you have following project pattern. Project - A that have many private repo (submodules). for eg: you can add a blog module(Individual Private repo) as submodule to the Project - A . like git submodule add path_to_private_repo_for_blog workbench/Vendor_folder/blog. Once you...

How to deploy a php application without running composer at production

php,composer-php

I found the solution. The correct way is to run composer install --prefer-dist --no-dev -o at the development system, copy the whole directory to the production server and it works....

Bug in vendor downloaded via composer [closed]

php,composer-php

When a VENDOR package has an error you can take several actions: 1) Modify vendor source code (maybe the worst decission) because when you update the package, your source code will be wrong again. 2) Check another version (not DEV) more stable that doesn't have this error. 3) Send the...

PHP Autoloader doesn't work on Ubuntu production server

php,ubuntu,composer-php

It's your wrong autoloading definition. You want to use the class PicoCore\Rest\ApiInitializer And you have these files: api/index.php api/vendor/... (with your required external dependencies) api/composer.json (with the autoloading mentioned in your question) api/core/PicoCore/rest/ApiInitializer.php And you have this autoloading configured: "autoload": { "psr-0": { "PicoCore\Rest\" : "PicoCore/rest" } } This is...

How to install CakePHP plugins from Composer into app/Plugin

php,cakephp,plugins,cakephp-2.0,composer-php

Add the required plugin line to /app/composer.json instead of adding it to /composer.json. Minimum contents of app/composer.json: { "require": { "ichikaway/cakephp-mongodb": "2.2.*@dev" } } Then just run composer update from your console while in the app folder instead of from your project's root folder. This will install it to the...

Composer: Require a package with custom namespace

php,composer-php,alias

No, there is nothing you can do to shorten these namespaces. Composer doesn't have to do anything with PHP namespaces. The name you use to identify the software package is unrelated to the PHP namespace. They don't have to match in any way. Composer only provides an autoloader that will...

Beginner trouble understanding composer and frameworks

php,composer-php

What you have to understand is that Composer is only a package manager, it will allow you to download some libraries (and their dependencies), and provide you an autoloader file to include on your files, so that you can use library classes. Actually, you better install Composer on your local...

ratchet HttpServer class not found

php,websocket,composer-php,ratchet

PHP namespaces are case sensitive, so try Http instead of http: use Ratchet\Http\HttpServer; ...

Deleting migrations results in an Exception

php,laravel,laravel-5,composer-php,autoload

Go into your mysql database manually (PHPMyAdmin) and remove the migrations table. With the steps you've taken above and doing this should solve your issue

Having trouble while installing composer on ubuntu

php,ubuntu,laravel,curl,composer-php

Try to update your local certificates: sudo update-ca-certificates or cd /etc/ssl/certs sudo wget http://curl.haxx.se/ca/cacert.pem And then use this cert file on the command: curl -sS https://getcomposer.org/installer | php -- --cafile=/etc/ssl/certs/cacert.pem All in all: your pull new certs and use this on the cURL command on the CLI. The next step...

PHPunit no tests execute on Travis CI

php,phpunit,composer-php,travis-ci

The directory containing your tests is incorrect. The correct path would be phpUnitTutorial/tests. Note that Windows does not care about case sensitivity, but everyone else in the world does. Best thing would be to always use lower case for paths, or double check you are using the correct case everywhere...

PSR 4 autoload not finding class

php,composer-php,psr-4

Autoload section should be "autoload" : { "psr-4" : {"Filters\\" : "src/Filters"} } ...

Composer scripts

package,laravel-5,composer-php

Composer only runs commands in the main composer.json file, not that of any package. If you want to have the commands executed, they have to manually be added to the app that is using your package....

Composer require local package

php,composer-php

You can use Composer's repositories feature https://getcomposer.org/doc/05-repositories.md#loading-a-package-from-a-vcs-repository Instead of using the http format, specify a file path on disk....

Running Composer with MAMP: Unable to load dynamic library mcrypt.so

php,composer-php,mamp,mcrypt

You're trying to load PHP 5.3 libraries into a PHP 5.5 installation. You need to install a PHP 5.5 version of mcrypt. If you're using Homebrew to manage your PHP install (which you should), brew install php55-mcrypt will do the trick.

How to provide username and password for composer install?

php,bash,vagrant,composer-php

I don't know of a way to specify github credentials to composer via the command line but you can set them up prior to running the install command: Create an OAuth token on GitHub. Add it to the configuration running composer config -g github-oauth.github.com <oauthtoken> Alternatively you can modify the...

how to safely update way generators 3.0 package in laravel 4.2

laravel,laravel-4,package,composer-php,way-generators

Update your composer.json file to use "way/generators": "~2.0". Once that is done, run the following command: composer update "way/generators" --dev By providing the package name to the composer command, composer will only update the specified package....

`with_dict expects a dict` - Ansible global composer and kosssi.composer

php,composer-php,ansible,kosssi-composer

A dictionary is also known as an associative array. There are two ways to define them in YAML, and you're mixing them up, which confuses the parser. Either write the whole thing in JSON style: - hosts: myhosts remote_user: vagrant sudo: true roles: - { role: kosssi.composer, composer_path_env: true, composer_home_path:...