CSharpRepl icon indicating copy to clipboard operation
CSharpRepl copied to clipboard

Runtime Configuration file support

Open SFM61319 opened this issue 3 years ago • 2 comments

Feature Description

Support for RC/Settings files (example, ~/.csharpreplrc[.json|.xml|.y[a]ml]) that are read before (and maybe even during?) program execution. A much better alternative to passing options each and every time.

.csharpreplrc.json:

{
    "$schema": "https://raw.githubusercontent.com/waf/CSharpRepl/main/.csharpreplrc.schema.json",
    "theme": "/path/to/theme.json",
    "usings": [ "System", "System.Text", "System.Collections.Generic" ],
    ...
}

(Also does CSharpRepl support Visual Studio Code Developer: Generate Color Theme From Current Settings theme JSON files?)

SFM61319 avatar Jul 11 '22 14:07 SFM61319

(Also on a side note, you might want to edit the README.md and change Ctrl+Enter (and similar KBD elements) to CtrlEnter (remove + and separate the keys/put them in their own <kbd /> elements), thats the way most people use them)

SFM61319 avatar Jul 11 '22 14:07 SFM61319

Thanks for the issue! There is some basic support for this in the current main branch (https://github.com/waf/CSharpRepl/pull/131), but it's not in a release yet.

Right now the config file is .rsp format (the same that csi.exe uses); I'd definitely love a JSON file format with a schema. After we get the next release out we can focus on this.

waf avatar Jul 11 '22 15:07 waf