summaryrefslogtreecommitdiffstats
path: root/src/wwwroot/libraries/fomantic/tasks/check-install.js
blob: a82297e82fb066af7fa170117d44634b21909c91 (plain) (blame)
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
/*******************************
 *        Check Install
 *******************************/

var
  // node dependencies
  gulp    = require('gulp'),
  console = require('better-console'),
  isSetup = require('./config/project/install').isSetup,

  install = require('./install'),
  watch   = require('./watch')
;

// export task
module.exports = function (callback) {

  setTimeout(function () {
    if (!isSetup()) {
      console.log('Starting install...');
      install(callback);
    } else {
      watch(callback);
    }
  }, 50); // Delay to allow console.clear to remove messages from check event

};