-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gruntfile.coffee
38 lines (33 loc) · 1.04 KB
/
Gruntfile.coffee
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
module.exports = (grunt) ->
grunt.loadNpmTasks 'grunt-contrib-coffee'
grunt.loadNpmTasks 'grunt-contrib-concat'
grunt.loadNpmTasks 'grunt-chmod'
grunt.initConfig
meta:
shebang: '#!/usr/bin/env node'
hacking: """
// Please don't edit this file directly. It is compiled from the CoffeeScript
// in summon.coffee. If you edit the CoffeeScript source and compile its changes,
// please keep the commits to this file separate. See the README for instructions
// on setting up a pre-commit hook to help with that.
"""
coffee:
default:
options:
bare: true
files:
'summon': 'summon.coffee'
# Prepend the node shebang line
concat:
options:
banner: '<%= meta.shebang %>\n\n<%= meta.hacking %>\n\n'
dist:
src: 'summon'
dest: 'summon'
# Make sure the file is executable
chmod:
options:
mode: '755'
target:
src: 'summon'
grunt.registerTask 'default', ['coffee', 'concat', 'chmod']