CakePHP Resque composer install error - cakephp

I have installed CakePHP via Composer with the following command
composer create-project --prefer-dist cakephp/app my_app_name
as mentioned in CakePHP documentation.
I need the kamisama/cake-resque plugin, but when i use composer require kamisama/cake-resque, I am getting the following errors
Using version ^4.1 for kamisama/cake-resque
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Nothing to install or update
Generating autoload files
> Cake\Composer\Installer\PluginInstaller::postAutoloadDump
Script Cake\Composer\Installer\PluginInstaller::postAutoloadDump
handling the post-autoload-dump event terminated with an exception
Installation failed, reverting ./composer.json to its original content.
[RuntimeException]
Unable to get primary namespace for package kamisama/cake-resque.
Ensure you have added proper 'autoload' section to your plugin's
config as stated in README on https://github.com/cakephp/plugin-installer
require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-update] [--update-no-dev] [--update-with-dependencies] [--ignore-platform-reqs] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--] [<packages>]...

Related

update cakephp3 with composer leads to missing dependencies

i want to update my cakephp 3.5 to 3.6 and i used composer
composer require --update-with-dependencies "cakephp/cakephp:3.6"
but e.g. dependency 'dotenv' is missing (it is not contained in my current local installation). dotenv has also no entry in composer. Do i have to update an composer.json manually?

angular directory structure not getting created in IntelliJ

I am following steps in IntelliJ to support Angular.
https://www.jetbrains.com/help/idea/2017.1/using-angular.html#install_angular_cli
In Generating an Angular application stub using Angular CLI section, I have to specify some package_name for Angular CLI field while setting up the project. What should be the value of package_name? I keep getting the following message but the angular directory structure doesn't get created.
"C:\Program Files\nodejs\node.exe" C:...\AppData\Roaming\npm\node_modules\angular-cli\bin\ng new angularIntelliJ8 --dir=.
As a forewarning, we are moving the CLI npm package to "#angular/cli" with the next release,
which will only support Node 6.9 and greater. This package will be officially deprecated
shortly after.
To disable this warning use "ng set --global warnings.packageDeprecation=false".
Directory '.' already exists.
Done
I have specified the path as C:\Users\Manu\AppData\Roaming\npm\node_modules\angular-cli
I notice that if I run ng new angularIntelliJ8 on cmd then the angular directory structure gets created. But doing where ng shows the following path for ng
>where ng
C:\..\AppData\Roaming\npm\ng
C:\..\AppData\Roaming\npm\ng.cmd
If I use above paths in Angular CLI, I get error that IntelliJ couldn't find bin/ng
Also, if I run '"C:\Program Files\nodejs\node.exe" C:\Users\Manu\AppData\Roaming\npm\node_modules\angular-cli\bin\ng new angularIntelliJ10' on cmd terminal manually (without --dir=.), the structure gets created.
Am I specifying wrong path for Angular CLI?
Please update angular-cli to the most recent version (see Updating Angular CLI for instructions). Both the package name/location and CLI interface have changed since beta 28, and IDEA 2017.1.* only supports new cli versions.
Once you have a new cli package installed, specify C:\Users\Manu\AppData\Roaming\npm\node_modules\#angular\cli as a package name in New Project wizard

Download persice i18n locale in Angularjs using Bower

I'm using Wiredep tool with Gulp, to inject into my index.html on the run everything that I install using Bower. I don't want to download all the files listed here.
Is there a way to download only precise locale?
I've tried
bower install angular-i18n/angular-locale_uk-ua.js
And I got
fatal: remote error:
Repository not found.
In order to do this angular/bower-angular-i18n repo should be forked.
If the concern is to lower bower_components footprint on server side, postinstall hook can be supplied in .bowerrc to delete extra files from the package after installation.

How to install authentication plugins in grails 3.0.1?

I want to install authentication plug-in in my grails project so I used grails install-plugin spring-security-core command but is gives an error:
Error Command not found install-plugin
Did you mean: install or list-plugins or plugin-info?.
Grails version : 3.0.1
I am really new to grails so I am not able to understand how to install plug-in in it.
In grails 3 install-pugin is removed. Now it's enough to add a dependency in your projects build.gradle to install the desired plugin. In your case to install spring-security-core plugin add the dependency as follow:
dependencies {
...
compile "org.grails.plugins:spring-security-core:3.0.4"
...
}
And then simply run grails run-app and check that the plugin is installed.
install-plugin is now deprecated, please see the Grails documentation here for the correct way to install pluggins
https://grails.github.io/grails-doc/latest/guide/plugins.html

Uninstall one package from composer without updating everything else

I have a project that uses Composer. I want to remove a package (in my case Aspect Mock).
I remove the dependency from composer.json and delete all the vendor packages manually. Then I run php composer.phar install. It says
Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to update them.
I do not want this warning, so I run php composer.phar update and it updates all my packages in composer.lock (which we have in SCM).
I do not want that either (I only want to remove one package) so instead of running composer update, I manually remove all references to the removable package in composer.lock. Composer install still gives me this warning.
How can I delete a package installed by composer without updating everything else, and without introducing warnings into my workflow?
Updating just the lock file: composer update --lock
Removing a package, deleting their files, updating the lock file all in one command without dealing with naked JSON data: composer remove vendor/package or composer remove --dev vendor/package - just the opposite of require.
composer remove vendor/package is the command you are looking for. It removes the package from composer.json as well as deleting it from the vendor folder.
You can read about its options at https://getcomposer.org/doc/03-cli.md#remove

Resources