]> git.immae.eu Git - github/fretlink/purs-loader.git/commitdiff
Update debug statements during build/bundle
authoreric thul <thul.eric@gmail.com>
Sat, 19 Nov 2016 17:47:18 +0000 (12:47 -0500)
committereric thul <thul.eric@gmail.com>
Sat, 19 Nov 2016 17:47:18 +0000 (12:47 -0500)
src/Psc.js

index 0aa9fe2f90c5e2929d060fdce739c8c315259008..437eb9176e444406a436f9cfffc1c9c5ffe84a5a 100644 (file)
@@ -29,7 +29,7 @@ function compile(psModule) {
   debug('spawning compiler %s %o', options.psc, args)
 
   return (new Promise((resolve, reject) => {
-    debug('\nCompiling PureScript...')
+    debug('compiling PureScript...')
 
     const compilation = spawn(options.psc, args)
 
@@ -37,7 +37,7 @@ function compile(psModule) {
     compilation.stderr.on('data', data => stderr.push(data.toString()))
 
     compilation.on('close', code => {
-      debug('Finished compiling PureScript.')
+      debug('finished compiling PureScript.')
       cache.compilationFinished = true
       if (code !== 0) {
         cache.errors = stderr.join('')
@@ -74,13 +74,14 @@ function bundle(options, cache) {
   debug('spawning bundler %s %o', options.pscBundle, args.join(' '))
 
   return (new Promise((resolve, reject) => {
-    debug('Bundling PureScript...')
+    debug('bundling PureScript...')
 
     const compilation = spawn(options.pscBundle, args)
 
     compilation.stdout.on('data', data => stdout.push(data.toString()))
     compilation.stderr.on('data', data => stderr.push(data.toString()))
     compilation.on('close', code => {
+      debug('finished bundling PureScript.')
       if (code !== 0) {
         cache.errors = (cache.errors || '') + stderr.join('')
         return reject(new Error('bundling failed'))