代码拉取完成,页面将自动刷新
同步操作将从 loveyu/Linger 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
var gulp = require('gulp'),
minifyCss = require('gulp-minify-css'),
concat = require('gulp-concat'),
uglify = require('gulp-uglify'),
rename = require('gulp-rename'),
clean = require('gulp-clean'),
htmlMin = require('gulp-htmlmin'),
fs = require('fs'),
child_process = require('child_process');
/**
* Vue 的数据压缩
*/
gulp.task("vue_mini_js", function () {
child_process.execSync("php make_vue_script.php");
var path = 'web_resource/vue/';
if (fs.existsSync(path + "dist.min.js")) {
fs.unlinkSync(path + 'dist.min.js');
}
return gulp.src(path + 'dist.js')
.pipe(uglify())
.pipe(rename({suffix: '.min'}))
.pipe(gulp.dest(path));
});
/**
* Vue JS 输出
*/
gulp.task("vue_js", ['vue_mini_js'], function () {
gulp.src([
'web_resource/director/director.min.js',
'web_resource/vue/vue.min.js',
'web_resource/vue/dist.min.js'
]).pipe(concat('vue.min.js'))
.pipe(gulp.dest('web/style/default/'));
gulp.src([
'web_resource/director/director.js',
'web_resource/vue/vue.js',
'web_resource/vue/dist.js'
]).pipe(concat('vue.js'))
.pipe(gulp.dest('web/style/default/'));
});
gulp.task('admin_v2_plugin_js', function () {
var list = [
'fastclick/fastclick.js',
'sparkline/jquery.sparkline.js',
'jvectormap/jquery-jvectormap-1.2.2.min.js',
'jvectormap/jquery-jvectormap-world-mill-en.js',
'slimScroll/jquery.slimscroll.js',
'chartjs/Chart.js'
];
for (var i = 0; i < list.length; i++) {
list[i] = "bower_components/admin-lte/plugins/" + list[i];
}
return gulp.src(list)
.pipe(concat('plugin.js'))
.pipe(gulp.dest('web/style/default/admin-v2'))
.pipe(uglify())
.pipe(rename({suffix: '.min'}))
.pipe(gulp.dest('web/style/default/admin-v2'));
});
gulp.task('admin_v2_plugin_css', function () {
var list = [
'jvectormap/jquery-jvectormap-1.2.2.css'
];
for (var i = 0; i < list.length; i++) {
list[i] = "bower_components/admin-lte/plugins/" + list[i];
}
return gulp.src(list)
.pipe(concat('plugin.css'))
.pipe(gulp.dest('web/style/default/admin-v2'))
.pipe(minifyCss())
.pipe(rename({suffix: '.min'}))
.pipe(gulp.dest('web/style/default/admin-v2'));
});
gulp.task('admin_v2_plugin', ['admin_v2_plugin_css', 'admin_v2_plugin_js']);
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。