-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgulpfile.ls
More file actions
58 lines (49 loc) · 1.12 KB
/
gulpfile.ls
File metadata and controls
58 lines (49 loc) · 1.12 KB
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
require! <[
run-sequence
gulp
gulp-if
gulp-karma
gulp-concat
gulp-purescript
gulp-filter
]>
paths =
test:
src: <[
bower_components/chai/chai.js
bower_components/purescript-*/src/**/*.purs
bower_components/purescript-*/src/**/*.purs.hs
src/**/*.purs
]>
dest: "tmp"
options =
test:
output: "Test.js"
main: true
externs: "extern.purs"
fil = gulp-filter (file) -> not /Test/ig.test file.path
build = (k) -> ->
x = paths[k]
o = options[k]
psc = gulp-purescript.psc o
psc.on "error" ({message}) ->
console.error message
psc.end()
gulp.src x.src
.pipe gulp-if /.purs/, psc
.pipe gulp-concat o.output
.pipe gulp.dest x.dest
gulp.task "build:test", build "test"
gulp.task "test:unit" ->
gulp.src options.test.output .pipe gulp-karma(
configFile : "./karma.conf.ls"
noColors : true
action : "run"
)
gulp.task "doc" ->
gulp.src "src/**/*.purs"
.pipe fil
.pipe gulp-purescript.docgen()
.pipe gulp.dest "DocGen.md"
gulp.task "test" -> run-sequence "build:test" "test:unit"
gulp.task "travis" <[test]>