Skip to content

Commit c0eba38

Browse files
add editor run actions for Swift executables (#1378)
1 parent ce0b454 commit c0eba38

File tree

1 file changed

+18
-4
lines changed

1 file changed

+18
-4
lines changed

package.json

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -148,13 +148,15 @@
148148
},
149149
{
150150
"command": "swift.run",
151-
"title": "Run Build",
152-
"category": "Swift"
151+
"title": "Run Swift executable",
152+
"category": "Swift",
153+
"icon": "$(play)"
153154
},
154155
{
155156
"command": "swift.debug",
156-
"title": "Debug Build",
157-
"category": "Swift"
157+
"title": "Debug Swift executable",
158+
"category": "Swift",
159+
"icon": "$(debug)"
158160
},
159161
{
160162
"command": "swift.resetPackage",
@@ -898,6 +900,18 @@
898900
"group": "navigation"
899901
}
900902
],
903+
"editor/title/run": [
904+
{
905+
"command": "swift.run",
906+
"group": "navigation@0",
907+
"when": "resourceLangId == swift && swift.currentTargetType == 'executable'"
908+
},
909+
{
910+
"command": "swift.debug",
911+
"group": "navigation@0",
912+
"when": "resourceLangId == swift && swift.currentTargetType == 'executable'"
913+
}
914+
],
901915
"swift.editor": [
902916
{
903917
"command": "swift.run",

0 commit comments

Comments
 (0)