Skip to content
This repository was archived by the owner on Jun 22, 2024. It is now read-only.

Commit 870748e

Browse files
committed
Running default target did not work #94
1 parent a498576 commit 870748e

File tree

3 files changed

+15
-7
lines changed

3 files changed

+15
-7
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## Unreleased
44

5+
## 2.11.2
6+
7+
- Running default target did not work #94
8+
59
## 2.11.1
610

711
- [Disable C and C++ for sourcekit-lsp](https://forums.swift.org/t/disable-sourcekit-lsp-for-c-files/30717/3)

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"url": "https://github.com/vknabel"
99
},
1010
"license": "Apache-2.0",
11-
"version": "2.11.1",
11+
"version": "2.11.2",
1212
"publisher": "vknabel",
1313
"icon": "icons/icon.png",
1414
"galleryBanner": {

src/toolchain/SwiftTools.ts

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -197,12 +197,16 @@ export class Toolchain {
197197
setRunning(true);
198198
output.run.clear();
199199
output.run.log(`running ${target ? target : "package"}…`);
200-
const { proc } = this.spawnSwiftProc(["run", target], output.run, (code, signal) => {
201-
// handle termination here
202-
output.run.log(`Process exited. code=${code} signal=${signal}`);
203-
setRunning(false);
204-
this.runProc = undefined;
205-
});
200+
const { proc } = this.spawnSwiftProc(
201+
target ? ["run", target] : ["run"],
202+
output.run,
203+
(code, signal) => {
204+
// handle termination here
205+
output.run.log(`Process exited. code=${code} signal=${signal}`);
206+
setRunning(false);
207+
this.runProc = undefined;
208+
}
209+
);
206210
this.runProc = proc;
207211
}
208212

0 commit comments

Comments
 (0)