1 Star 0 Fork 0

Evan / passman-webextension

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
Gruntfile.js 3.42 KB
一键复制 编辑 原始数据 按行查看 历史
Your Name 提交于 2017-06-08 09:52 . Don't copy fixLocale.js to dist folder.
module.exports = function (grunt) {
var jsResources = [];
// Project configuration.
grunt.initConfig({
jsResources: [],
cssResources: [],
pkg: grunt.file.readJSON('package.json'),
jshint: {
options: {
reporter: require('jshint-stylish'),
curly: false,
eqeqeq: true,
eqnull: true,
browser: true,
globals: {
"angular": true,
"PassmanImporter": true,
"PassmanExporter": true,
"OC": true,
"window": true,
"console": true,
"CRYPTO": true,
"C_Promise": true,
"forge": true,
"sjcl": true,
"jQuery": true,
"$": true,
"_": true,
"oc_requesttoken": true
}
},
all: ['js/*', '!js/vendor']
},
mkdir: {
dist: {
options: {
mode: 0700,
create: ['dist']
}
}
},
copy: {
dist: {
src: [
'**',
'*.xpi',
'!fixLocale.js',
'!tests/*/**/*',
'!tests/*',
'!tests',
'!style/*/**/*',
'!style/*',
'!style',
'!node_modules/*',
'!node_modules/**',
'!dist/**',
'!dist/*',
'!.drone.yml',
'!.gitignore',
'!.jshintrc',
'!.scrutinizer.yml',
'!.travis.yml',
'!Gruntfile.js',
'!karma.conf.js',
'!launch_phpunit.sh',
'!Makefile',
'!package.json',
'!phpunit.*',
'!Dockerfile',
'!*.md',
'!*.zip',
'!swagger.yaml',
'!.tx'
],
dest: 'dist/'
}
},
karma: {
unit: {
configFile: './karma.conf.js',
background: false
}
},
compress: {
dist: {
options: {
archive: 'extension.zip'
},
files: [
{src: ['**'], dest: '.', cwd: 'dist/'}, // includes files in path
]
}
},
clean: {
dist: ['dist']
},
execute: {
fixLocale: {
src: ['fixLocale.js']
}
}
});
grunt.loadNpmTasks('grunt-mkdir');
grunt.loadNpmTasks('grunt-contrib-compress');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-execute');
grunt.loadNpmTasks('grunt-karma');
// Default task(s).
grunt.registerTask('test', ['karma', 'jshint']);
grunt.registerTask('build', ['execute:fixLocale','jshint', 'clean:dist', 'mkdir:dist', 'copy:dist', 'compress:dist']);
grunt.registerTask('dist', ['']);
};
JavaScript
1
https://gitee.com/creno/passman-webextension.git
git@gitee.com:creno/passman-webextension.git
creno
passman-webextension
passman-webextension
master

搜索帮助