Asset management package for Laravel 4, that harnesses the power of GruntJS
This package is no long being maintained!! Since discovering the Gulp task runner, and finding how easy it is to install, setup and use I've opted to drop GruntJS from my workflow.
Please help me by trialing out my package and providing feedback
This package is design to help with asset management and front-end workflow when developing in Laravel 4.
The package can do the following:
Before using this package please make sure you have bower & node installed globally. This can be done by running the following command:
npm install -g bower && npm install -g grunt-cli
To install the 'Laravel 4 + Grunt Asset Workflow Package' simply add the following to your composer.json
composer update --devin your terminal.
Next, add the following line to the end of you
Finally, run the following command to add the configuration file to your
php artisan config:publish jason-morton-nz/laravel-gruntor
php artisan grunt:config
You can configure many of the settings for this package, by traversing to it's configuration file. This file is located in you project's vendor directory, as below:
This file is heavily commented, so hopefully each setting should be self explanatory.
Note: please try not to edit the
grunfile.jsdirectly. Instead make your required changes in the config.php file, then run
php artisan grunt:setupto apply the changes.
So, how do you use this package? Well we've tried to make it as simple as possible. There's just 3 commands:
grunt:setupcommand is used to setup your required asset + grunt workflow. You use the command as follows:
php artisan grunt:setup
The command will ask you a selection of questions, and the rest is all done for you.
grunt:buildcommand will run the grunt task runner and lint, compile, minify all your files, according to how you want things done. You use the command as follows:
php artisan grunt:build
php artisan grunt:watch
Note: That live reload will only work if you have a compatible browser (Chrome & Firefox) with the LiveReload plugin installed.
bower:setupcommand will setup
.bowerrcfiles based upon the configuration settings you've specified in this packages
php artisan bower:setup
bower:installcommand is used to install you bower dependencies. You can use the command as follows:
php artisan bower:install
bower:updatecommand update your bower dependencies to newer versions if available. You can use the command as follows:
php artisan bower:update
If you find any bugs, issues errors or believe we could add further useful functionality. Let us know via the github issues page for this project here - https://github.com/JasonMortonNZ/laravel-grunt/issues.
Here's a list of people who have helped by contributing to this project to date: