]> git.immae.eu Git - github/fretlink/purs-loader.git/blobdiff - src/Psc.js
Don't console.log unless it is needed
[github/fretlink/purs-loader.git] / src / Psc.js
index 595494459746b25871a33c176751dcccf4906b53..0aa9fe2f90c5e2929d060fdce739c8c315259008 100644 (file)
@@ -29,7 +29,7 @@ function compile(psModule) {
   debug('spawning compiler %s %o', options.psc, args)
 
   return (new Promise((resolve, reject) => {
-    console.log('\nCompiling PureScript...')
+    debug('\nCompiling 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 => {
-      console.log('Finished compiling PureScript.')
+      debug('Finished compiling PureScript.')
       cache.compilationFinished = true
       if (code !== 0) {
         cache.errors = stderr.join('')
@@ -74,7 +74,7 @@ function bundle(options, cache) {
   debug('spawning bundler %s %o', options.pscBundle, args.join(' '))
 
   return (new Promise((resolve, reject) => {
-    console.log('Bundling PureScript...')
+    debug('Bundling PureScript...')
 
     const compilation = spawn(options.pscBundle, args)