I.e for running C or C++ or D code i'd have to prepend and append some code before running it
For C it'd be something like
#include <stdio.h>
int main() {
// SELECTED CODE GOES HERE
return 0;
}
For C++ it'd be something like
#include <iostream>
int main() {
// SELECTED CODE GOES HERE
return 0;
}
For D it'd be something like
/+ dub.sdl:
name "test"
+/
import std;
void main() {
// SELECTED CODE GOES HERE
}
So possibly allow in file_types to have definition of something like file_template, i.e
opts = {
file_types = {
d = {
cmd = "dub run --single",
file_template = '/+ dub.sdl:\nname "test"\n+/\nimport std;\nvoid main() {\n${CODE}\n}\n'
}
}
}
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too