powershell-command-executor
powershell-command-executor copied to clipboard
Generalize command service functionality away from powershell only
There are several things that can be done to make this more of a generic "shell agnostic" wrapper around stateless-process-command-proxy
- Support configurable function in constructor to handle argument sanitization
- Support configurable function in constructor to permit modifcation of all arguments, i.e. for PS commands the PSCommandService auto prepends a "-" to all argument names
- Rename to CommandService, get rid of PS
Can this be used to run Powershell scripts, or is it just for commands ? Thanks.
Sure, but I suggest you just use https://github.com/bitsofinfo/stateful-process-command-proxy instead (the lower level module). Create your custom powershell script then invoke it via that. This project (powershell-command-executor) is for a registry of pre-defined commands, see the README for details.