-
Notifications
You must be signed in to change notification settings - Fork 3
/
gulpfile.js
56 lines (54 loc) · 1.56 KB
/
gulpfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
var elixir = require('laravel-elixir');
var gulp = require('gulp');
/*
|--------------------------------------------------------------------------
| Elixir Asset Management
|--------------------------------------------------------------------------
|
| Elixir provides a clean, fluent API for defining some basic Gulp tasks
| for your Laravel application. By default, we are compiling the Sass
| file for our application, as well as publishing vendor resources.
|
*/
var js = [
'jQuery-2.1.4.min.js',
'bootstrap.min.js',
'gushi/common.js',
'toast.js',
'clipboard.min.js'
];
elixir(function(mix) {
mix.sass('app.scss')
.sass('zhuanlan.scss')
.scripts(js, './public/js/app.js')
.version([
'css/app.css',
'css/zhuanlan.css',
'js/app.js'
]);
});
// var elixir = require('laravel-elixir');
// elixir(function(mix) {
// mix.less('admin-lte/AdminLTE.less', 'public/la-assets/css');
// mix.less('bootstrap/bootstrap.less', 'public/la-assets/css');
// });
/*
var minify = require('gulp-minify');
gulp.task('compress', function() {
gulp.src('lib/*.js')
.pipe(minify({
ext:{
src:'-debug.js',
min:'.js'
},
exclude: ['tasks'],
ignoreFiles: ['.combo.js', '-min.js']
}))
.pipe(gulp.dest('dist'))
});
*/
//监视文件变化,路径下文件发生变化执行
gulp.task('watch', function() {
// 看守所有.scss文档,发生变化时执行压缩程序
gulp.watch(['resources/assets/sass/**/*.scss'] ,['default']);
});