Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add deleteDevChannelBeforeInstall launch option #494

Merged
merged 3 commits into from
Jul 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 12 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
"node-ssdp": "^4.0.0",
"postman-request": "^2.88.1-postman.32",
"pretty-bytes": "^5.6.0",
"roku-debug": "^0.20.2",
"roku-debug": "^0.20.3",
"roku-deploy": "^3.10.3",
"roku-test-automation": "^2.0.0-beta.19",
"semver": "^7.1.3",
Expand Down Expand Up @@ -794,6 +794,11 @@
],
"default": "log",
"description": "The level of logging that should be done during a debug session."
},
"deleteDevChannelBeforeInstall": {
"type": "boolean",
"default": false,
"description": "Delete any currently installed dev channel before starting the debug session"
}
}
}
Expand Down Expand Up @@ -2239,6 +2244,12 @@
"description": "Should rendezvous tracking be enabled on launch? If `true`: turn on ECP rendezvous tracking, or turn on 8080 rendezvous tracking if ECP unsupported. If `false`, turn off both.",
"default": true,
"scope": "resource"
},
"brightscript.debug.deleteDevChannelBeforeInstall": {
"type": "boolean",
"default": false,
"description": "Delete any currently installed dev channel before starting the debug session",
"scope": "resource"
}
}
},
Expand Down
4 changes: 3 additions & 1 deletion src/DebugConfigurationProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@ export class BrightScriptDebugConfigurationProvider implements DebugConfiguratio
packagePort: 80,
enableDebugProtocol: false,
remotePort: 8060,
rendezvousTracking: true
rendezvousTracking: true,
deleteDevChannelBeforeInstall: false
};

let config: any = vscode.workspace.getConfiguration('brightscript') || {};
Expand Down Expand Up @@ -241,6 +242,7 @@ export class BrightScriptDebugConfigurationProvider implements DebugConfiguratio
config.enableDebugProtocol = config.enableDebugProtocol ? true : false;
config.cwd = folderUri.fsPath;
config.rendezvousTracking = config.rendezvousTracking === false ? false : true;
config.deleteDevChannelBeforeInstall = config.deleteDevChannelBeforeInstall === true;

if (config.request !== 'launch') {
await vscode.window.showErrorMessage(`roku-debug only supports the 'launch' request type`);
Expand Down