Skip to content
This repository has been archived by the owner on Sep 15, 2020. It is now read-only.

Commit

Permalink
Delete and re-add project each time wml s is run
Browse files Browse the repository at this point in the history
This addresses wix-incubator#19.
  • Loading branch information
benallfree authored and qkdreyer committed Feb 19, 2018
1 parent e10c213 commit fbb04e6
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/watchProject.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,18 @@ var Q = require('q');
module.exports = function (params) {
var deferred = Q.defer();

params.client.command(['watch-project', params.src], (error, resp) => {
params.client.command(['watch-del', params.src], (error, resp) => {
if (error) {
deferred.reject(error);
} else {
deferred.resolve(resp);
params.client.command(['watch-project', params.src], (error, resp) => {
if (error) {
deferred.reject(error);
} else {
deferred.resolve(resp);
}

});
}

});
Expand Down

0 comments on commit fbb04e6

Please sign in to comment.