I'm using the MvcScaffolding NuGet Package to scaffold a couple of Controllers. I'm currently repeating the same process ie. Scaffold Controller MyController -Repository -Force. I do this for a number of controllers. Is there a way to run a script on the console where I can put a couple of commands and run them once?
I'm a Powershell noob, so there may be a better way, but I just ran this in the Package Manager Console:
$controllers = "test", "test2"; foreach ($controller in $controllers) { echo $controller }
And it seemed to work, so maybe something like this would work?
$controllers = "test", "test2"; foreach ($controller in $controllers) { Scaffold Controller $controller -Repository -Force }
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With