ollieread / multiauth

Laravel multi auth
442 stars 109 forks source link

Multiauth composer update issue #33

Closed hughsmith10 closed 10 years ago

hughsmith10 commented 10 years ago

Ollie... I tried installing Multiauth using composer by adding to my composer.json, then running composer update. Also did composer dump-autoload after adding the lines to app.php, but then realized that the files did not appear to get downloaded into my vendor directory.

➜ www git:(master) ✗ php artisan dump-autoload PHP Fatal error: Class 'Ollieread\Multiauth\MultiauthServiceProvider' not found in /www/mysite/vendor/laravel/framework/src/Illuminate/Foundation/ProviderRepository.php on line 158

Any ideas? Really appreciate your help.

ollieread commented 10 years ago

What did composer update return?

hughsmith10 commented 10 years ago

At what point in your instructions should I run composer update? I tried doing it after I had modified app.php (the first time)... then I reversed the changes in app.php and tried again. This is what I got just now when I tried it again (with app.php modified as per the instructions).

www git:(master) ✗ composer update Loading composer repositories with package information Updating dependencies (including require-dev)

Writing lock file Generating autoload files Generating optimized class loader

Thanks for looking at this Ollie.

ollieread commented 10 years ago

You should add the package to composer.json

"require": {
    "ollieread/multiauth": "dev-master"
}

Then run composer update or composer install. Once you have confirmed the installation of this package, you can then modify app.php and auth.php accordingly. Do not modify app.php prior to installing the package as you will get lots of class not defined errors.

hughsmith10 commented 10 years ago

Yep... that's exactly what I did, but the files are not being pulled in by composer. Not sure why.

ollieread commented 10 years ago

Can you post you composer.json config?

hughsmith10 commented 10 years ago
{
"name": "laravel/laravel"
,"description": "The Laravel Framework."
,"keywords": ["framework", "laravel"]
,"license": "MIT"
,"require": {
    "laravel/framework": "4.1.*"
    ,"mustache/mustache": "dev-dev"
    ,"stripe/stripe-php": "v1.9.1"
    ,"jv2222/ezsql": "dev-master"
    ,"iron-io/iron_mq": "1.4.8"
    ,"rackspace/php-opencloud": "dev-master"
    ,"intervention/image": "dev-master"
    ,"ollieread/multiauth": "dev-master"
}
,"require-dev": {
    "fzaninotto/faker": "dev-master"
    ,"itsgoingd/clockwork": "1.*"
    ,"phpunit/phpunit": "4.0.*"
    ,"mockery/mockery": "0.9.*"
}
,"autoload": {
    "classmap": [
        "app/commands"
        ,"app/controllers"
        ,"app/models"
        ,"app/database/migrations"
        ,"app/database/seeds"
        ,"app/tests/TestCase.php"
        ,"app/LIBS"
        ,"app/LIBS/ezSQL"
    ]
    ,"psr-0": {
        "Acme": "app/"
    }
}
,"scripts": {
    "post-install-cmd": [
        "php artisan optimize"
    ]
    ,"post-update-cmd": [
        "php artisan clear-compiled",
        "php artisan optimize"
    ]
    ,"post-create-project-cmd": [
        "php artisan key:generate"
    ]
}
,"config": {
    "preferred-install": "dist"
}
,"minimum-stability": "dev"

}

ollieread commented 10 years ago

Try deleting the vendor directory, and composer.lock, then run composer install

hughsmith10 commented 10 years ago

ok

hughsmith10 commented 10 years ago

Awesome! Looks like that brought in the files this time... but on a side note it gave me a bunch of warnings. I know it's unrelated, but do you have any suggestions on this, or do i have to go install each of these one by one?

Thanks Ollie!

symfony/event-dispatcher suggests installing symfony/dependency-injection ()
symfony/translation suggests installing symfony/config ()
symfony/routing suggests installing symfony/config (For using the all-in-one router or any loader)
symfony/routing suggests installing symfony/expression-language (For using expression matching)
symfony/routing suggests installing doctrine/annotations (For using the annotation loader)
symfony/http-kernel suggests installing symfony/class-loader ()
symfony/http-kernel suggests installing symfony/config ()
symfony/http-kernel suggests installing symfony/dependency-injection ()
predis/predis suggests installing ext-phpiredis (Allows faster serialization and deserialization of the Redis protocol)
phpseclib/phpseclib suggests installing pear-pear/PHP_Compat (Install PHP_Compat to get phpseclib working on PHP < 4.3.3.)
monolog/monolog suggests installing ext-amqp (Allow sending log messages to an AMQP server (1.0+ required))
monolog/monolog suggests installing doctrine/couchdb (Allow sending log messages to a CouchDB server)
monolog/monolog suggests installing raven/raven (Allow sending log messages to a Sentry server)
monolog/monolog suggests installing ruflin/elastica (Allow sending log messages to an Elastic Search server)
monolog/monolog suggests installing aws/aws-sdk-php (Allow sending log messages to AWS services like DynamoDB)
monolog/monolog suggests installing graylog2/gelf-php (Allow sending log messages to a GrayLog2 server)
monolog/monolog suggests installing rollbar/rollbar (Allow sending log messages to Rollbar)
symfony/security suggests installing symfony/class-loader (For using the ACL generateSql script)
symfony/security suggests installing symfony/validator (For using the user password constraint)
symfony/security suggests installing doctrine/dbal (For using the built-in ACL implementation)
symfony/security suggests installing symfony/expression-language (For using the expression voter)
laravel/framework suggests installing doctrine/dbal (Allow renaming columns and dropping SQLite columns.)
intervention/image suggests installing intervention/imagecache (Caching extension for the Intervention Image library)
phpunit/phpunit suggests installing phpunit/php-invoker (~1.1)
ollieread commented 10 years ago

Excellent.

Those aren't warnings, they're just suggestions from the individual packages.

Also, in future, when posting things like logs and config, you can prepend each line with four spaces to make it code formatted, just like how the composer.json config looks in your previous post (I edited it).

Anyway, glad I could help.

hughsmith10 commented 10 years ago

Thanks! I appreciate it.