2 Star 0 Fork 97

fs_work/kindeditor

forked from luolonghao/kindeditor 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Gruntfile.js 1.76 KB
一键复制 编辑 原始数据 按行查看 历史
luolonghao 提交于 2013-03-20 18:08 . Add Gruntfile
module.exports = function(grunt) {
var BANNER = '/* <%= pkg.name %> <%= pkg.version %> (<%= grunt.template.today("yyyy-mm-dd") %>), Copyright (C) kindsoft.net, Licence: http://www.kindsoft.net/license.php */\n';
grunt.initConfig({
pkg : grunt.file.readJSON('package.json'),
concat : {
options : {
banner : BANNER,
stripBanners : true,
block : true,
line : true
},
dist : {
src : [
'src/header.js',
'src/core.js',
'src/config.js',
'src/event.js',
'src/html.js',
'src/selector.js',
'src/node.js',
'src/range.js',
'src/cmd.js',
'src/widget.js',
'src/edit.js',
'src/toolbar.js',
'src/menu.js',
'src/colorpicker.js',
'src/uploadbutton.js',
'src/dialog.js',
'src/tabs.js',
'src/ajax.js',
'src/main.js',
'src/footer.js'
],
dest : 'kindeditor.js'
}
},
uglify : {
options : {
banner : BANNER
},
build : {
src : 'src/<%= pkg.name %>.js',
dest : 'build/<%= pkg.name %>.min.js'
}
},
compress: {
main: {
options: {
archive: 'dist/<%= pkg.filename %>-<%= pkg.version %>.zip'
},
files: [
{src: ['path/*'], dest: 'internal_folder/', filter: 'isFile'}, // includes files in path
{src: ['path/**'], dest: 'internal_folder2/'}, // includes files in path and its subdirs
{expand: true, cwd: 'path/', src: ['**'], dest: 'internal_folder3/'}, // makes all src relative to cwd
{flatten: true, src: ['path/**'], dest: 'internal_folder4/', filter: 'isFile'} // flattens results to a single level
]
}
}
});
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-compress');
grunt.registerTask('default', ['concat', 'embed', 'uglify']);
};
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/fansens2017/kindeditor.git
[email protected]:fansens2017/kindeditor.git
fansens2017
kindeditor
kindeditor
os-page

搜索帮助