This repository has been archived by the owner on Jul 23, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathgulpfile.js
34 lines (26 loc) · 1.49 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
"use strict";
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Require packages
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
var gulp = require('gulp'),
uglify = require('gulp-uglify'),
rename = require("gulp-rename");
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Watch changes in files
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
gulp.task('watch', function () {
gulp.watch(['./jquery.autocolumnlist.js'], ['js']);
});
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// js
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
gulp.task('js', function () {
gulp.src(['./jquery.autocolumnlist.js'])
.pipe(uglify({preserveComments: 'license'}).on('error', function () {}))
.pipe(rename('jquery.autocolumnlist.min.js'))
.pipe(gulp.dest('./'));
});
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// default
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
gulp.task('default', ['js']);