i found something similar, with a bit more info.
gorgeEx("nim check " & filePath)
is there a way to pipe code into the nim compiler instead of a file path? I really hope these are not stupid questions, sorry if they areso I decided to make a simpler way then sending data into stdin and reading that out because it wouldn't work would just be creating a file in the nimcache and evaluating that. id just like comments or suggestions at this point
I am also doing this in a .nims file but it isn't hard to implement
const cgenf = nimCacheDir()&"/codegen.nim"
proc compilesE(code:string):tuple[output:string,exitCode:int] =
if not dirExists(nimCacheDir()):
mkdir(nimCacheDir())
writeFile(cgenf,code)
return gorgeEx("nim check "&cgenf)