1 Star 0 Fork 117

ryvius_key/Piplin

forked from Piplin/Piplin 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
gulpfile.js 3.95 KB
一键复制 编辑 原始数据 按行查看 历史
lianguan 提交于 2017-09-11 13:31 . Fixhub is a laravel 5.5 application now
var elixir = require('laravel-elixir');
require('laravel-elixir-remove');
require('laravel-elixir-bower-io');
elixir.config.production = true;
elixir.config.sourcemaps = false;
var gulp = require('gulp');
var shell = require('gulp-shell');
var jsuglify = require('gulp-uglify');
var Task = elixir.Task;
elixir.extend('lang', function() {
new Task('lang', function(){
return gulp.src('').pipe(shell('php artisan js-localization:refresh'));
});
});
elixir.extend('jsminify', function() {
new Task('jsminify', function () {
return gulp.src('public/js/*.js')
.pipe(jsuglify())
.pipe(gulp.dest('public/js/'));
});
});
var node_path = 'node_modules';
var paths = {
'backbone' : node_path + '/backbone',
'underscore' : node_path + '/underscore',
'moment' : node_path + '/moment',
'jquery' : node_path + '/jquery',
'jquery_sortable' : node_path + '/jquery-sortable',
'bootstrap_sass' : node_path + '/bootstrap-sass',
'socketio_client' : node_path + '/socket.io-client',
'ionicons' : node_path + '/ionicons',
'cropper' : node_path + '/cropper',
'toastr' : node_path + '/toastr',
'select2' : node_path + '/select2',
'ace' : node_path + '/ace-min-noconflict',
'raphael' : node_path + '/raphael',
'morris' : node_path + '/morris.js',
'localization' : '/../vendor/andywer/js-localization'
};
elixir(function(mix) {
mix
.sass('app.scss', 'public/css/app.css')
.styles([
paths.select2 + '/dist/css/select2.min.css',
paths.morris + '/morris.css',
paths.ionicons + '/css/ionicons.min.css',
paths.toastr + '/build/toastr.min.css',
paths.cropper + '/dist/cropper.min.css',
], 'public/css/vendor.css', './')
.scripts([
paths.jquery + '/dist/jquery.min.js',
paths.jquery_sortable + '/source/js/jquery-sortable-min.js',
paths.underscore + '/underscore-min.js',
paths.moment + '/min/moment.min.js',
paths.bootstrap_sass + '/assets/javascripts/bootstrap.min.js',
paths.select2 + '/dist/js/select2.min.js',
paths.raphael + '/raphael.min.js',
paths.morris + '/morris.min.js',
paths.backbone + '/backbone-min.js',
paths.socketio_client + '/socket.io.js',
paths.localization + '/resources/js/localization.js',
paths.toastr + '/build/toastr.min.js',
paths.cropper + '/dist/cropper.min.js'
], 'public/js/vendor.js', node_path)
.scripts([
paths.ace + '/ace.js',
paths.ace + '/mode-sh.js',
paths.ace + '/mode-php.js',
paths.ace + '/mode-yaml.js',
paths.ace + '/mode-ini.js'
], 'public/js/ace.js', node_path)
.scripts([
'app.js',
'projects.js',
'templates.js',
'keys.js',
'servers.js',
'heartbeats.js',
'notifySlacks.js',
'notifyEmails.js',
'shareFiles.js',
'configFiles.js',
'checkUrls.js',
'variables.js',
'deployment.js',
'commands.js',
'users.js',
'groups.js',
'links.js',
'tips.js',
'uploader.js',
//'issues.js',
'profile.js'
], 'public/js/app.js', 'resources/assets/js')
.jsminify()
.copy(paths.bootstrap_sass + '/assets/fonts/bootstrap/**', 'public/fonts')
.copy(paths.ionicons + '/fonts/**', 'public/fonts')
.version([
'public/css/app.css',
'public/css/vendor.css',
'public/js/app.js',
'public/js/ace.js',
'public/js/vendor.js'
])
.copy('public/fonts', 'public/build/fonts')
.remove([
'public/css',
'public/js',
'public/fonts'
])
.lang();
});
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
PHP
1
https://gitee.com/ryvius_key/Piplin.git
git@gitee.com:ryvius_key/Piplin.git
ryvius_key
Piplin
Piplin
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385