加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Gruntfile.coffee 1.45 KB
一键复制 编辑 原始数据 按行查看 历史
Ariel Yang 提交于 2016-07-05 13:36 . Init commit.
module.exports = (grunt) ->
# Project configuration.
grunt.initConfig
pkg: grunt.file.readJSON('package.json')
coffee:
src:
options:
bare: true
files: [
expand: true
src: 'src/**/*.coffee'
ext: '.js'
dest: 'build'
,
expand: true
src: 'spec/**/*.coffee'
ext: '.js'
dest: 'build'
]
clean:
build:
src: [
'build/*'
]
release:
src: [
'dist/*'
]
copy:
release:
files: [
expand: true
cwd: 'build/src'
src: '**/*.*'
dest: 'dist'
]
watch:
options:
spawn: false
test:
files: [
'src/**/*.coffee'
'spec/**/*.coffee'
]
tasks: [
'clean'
'coffee'
]
nodemon:
# Start dev environment.
dev:
script: 'build/src'
options:
nodeArgs: ['--harmony'] # Support ES6 when node version < 4.0
# These plugins provide necessary tasks.
grunt.loadNpmTasks 'grunt-contrib-coffee'
grunt.loadNpmTasks 'grunt-contrib-clean'
grunt.loadNpmTasks 'grunt-contrib-copy'
grunt.loadNpmTasks 'grunt-contrib-watch'
grunt.loadNpmTasks 'grunt-nodemon'
grunt.registerTask 'build', [
'clean'
'coffee'
'watch'
]
grunt.registerTask 'release', [
'clean'
'coffee'
'copy'
]
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化