Created
October 21, 2014 04:40
-
-
Save hailwood/4c13bdba0e484573557d to your computer and use it in GitHub Desktop.
Gulpfile.js
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var theme = 'default'; | |
| var elixir = require('laravel-elixir'); | |
| var path = new require('./Path')('resources/themes/'+theme+'/assets/', 'public/themes/'+theme+'/'); | |
| var sources = require('./'+path.input('../sources.js')); | |
| /* | |
| |---------------------------------------------------------------- | |
| | Have a Drink! | |
| |---------------------------------------------------------------- | |
| | | |
| | Elixir provides a clean, fluent API for defining some basic | |
| | Gulp tasks for your Laravel application. Elixir supports | |
| | several common CSS, JavaScript and even testing tools! | |
| | | |
| */ | |
| elixir(function (mix) { | |
| mix.assetsDir = path.input(); | |
| mix.cssOutput = path.output('css'); | |
| mix.jsOutput = path.output('js'); | |
| mix | |
| .less(sources.styles.less) | |
| .styles(sources.styles.vendor, path.input('styles/'), path.output('css/vendor.min.css')) | |
| .scripts(sources.scripts, path.input('scripts/'), path.output('js/application.min.js')) | |
| .copy(mix.prefixDirToFiles(path.input('fonts'), sources.fonts), path.output('fonts')) | |
| .copy(mix.prefixDirToFiles(path.input('images'), sources.images), path.output('images')) | |
| .routes() | |
| .events() | |
| .phpUnit(); | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment