Skip to content

Commit 8a307a2

Browse files
committed
[Issue #29] - Build -f throws exception if app is open in another window
1 parent 0aca4ca commit 8a307a2

2 files changed

Lines changed: 9 additions & 2 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
### Fixes
66

7+
- [Issue #29] - Build -f throws exception if app is open in another window
78
- [Issue #28] - App isn't merged without -f
89

910
## [0.2.1] - 2018-03-29

lib/chainlinks/builder.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,14 @@ let Builder = function() {
4242

4343
// Remove the bin forlder if force build
4444
if (payload.build.force) {
45-
shell.execSync("rm -rf " + buildPath);
46-
shouldBuild = true;
45+
try {
46+
shell.execSync("rm -rf " + buildPath);
47+
shouldBuild = true;
48+
49+
}
50+
catch (ex) {
51+
reject("Cannot remove build directory. Please make sure it is not open in another window.");
52+
}
4753
}
4854

4955
// Create build directory if necessary

0 commit comments

Comments
 (0)