A Laminas module for creating Gulp config files
Installation of this module uses composer. For composer documentation, please refer to getcomposer.org.
composer require riddlestone/brokkr-gulpfile
To include your js/sass files in the gulpfile, add them in portals to your module or site's config file:
<?php
return [
'portals' => [
'main' => [
'css' => [
realpath(__DIR__ . '/../resources/css/**/*.scss'),
],
'js' => [
realpath(__DIR__ . '/../resources/js/**/*.js'),
],
],
],
];
Note: Any other methods which brokkr-portals uses to provide portal information can also be used to get information to brokkr-gulpfile.
A gulpfile can now be created using the brokkr command gulpfile
:
vendor/bin/brokkr gulpfile
To set SASS options, include them in the sass_options
settings for your portal:
<?php
return [
'portals' => [
'main' => [
'css' => [
realpath(__DIR__ . '/../resources/css/**/*.scss'),
],
'sass_options' => [
'includePaths' => [
'vendor/someones/awesome-css-stuff/scss',
],
],
],
],
];
To change the template for your gulpfile, just copy view/gulpfile.js.php somewhere, change it, and add the new path to your module/site's config:
<?php
return [
'gulp' => [
'template' => realpath(__DIR__ . '/../view/gulpfile.js.php'),
],
];
To change the path of the final gulpfile, just add the following to your site/module's config:
<?php
return [
'gulp' => [
'target' => 'gulpfile2.js',
],
];
File issues at https://github.com/riddlestone/brokkr-gulpfile/issues