This CP article might help:
Compiling C# Code at Runtime[
^]
You could essentially create a CSharpScript app that loads a text file that contains C# "script" code and compile that script at runtime. You could also write pre-compiled plugins for your script runner app, and specify the DLL name on the commandline.
After doing that a couple of times, you might find that it's just easier to use powershell. :)