Closed geekyi closed 5 years ago
I would think it be better to have some of these integrated into the command palette.
Can you use DevOptions for it?
Something like:
commandsProvider.ts in execCommand
case Commands.Red_Compile: {
buildDir = redSettings.buildDir ||
vscode.workspace.rootPath ||
path.dirname(filePath);
compileFlag = redSettings.devOptions.join(" ") || "-c";
outputFilename = path.join(buildDir, path.parse(filePath).name);
if (guiMode) {
text = `${redExecutable} -t Windows -o "${outputFilename}" ${compileFlag} "${filePath}"`;
} else {
text = `${redExecutable} -o "${outputFilename}" ${compileFlag} "${filePath}"`;
}
} break;
default: {
text = 'echo "No red toolchain or red console"';
}
}
terminal.sendText(text);
terminal.show();
}
Settings.
"red.redPath": "\"C:\\Users\\Old Man\\red.exe\"",
"red.buildDir": "C:\\Users\\Old Man\\Desktop",
"red.devOptions": ["-r"],
@qtxie
@gltewalt Thanks. I'll try to update it in the next days.
i'm not sure if this is needed
recommend code runner
I have added "compile Red in Release mode", "clear libRedRT", "update libRedRT" commands. modifed the key bingdings:
{
"command": "red.interpret",
"key": "F6"
},
{
"command": "red.interpretGUI",
"key": "ctrl+F6"
},
{
"command": "red.compile",
"key": "F7"
},
{
"command": "red.compileGUI",
"key": "ctrl+F7"
},
{
"command": "red.compileRelease",
"key": "ctrl+shift+F7"
},
{
"command": "reds.compile",
"key": "F8"
},
{
"command": "red.commandMenu",
"key": "ctrl+k ctrl+m"
}
We currently have 4 commands. Add more for other commonly used compilation options.
-u
update libRedRT-r
compile in release mode (I don't use that often)clear
libRedRT and related files