stevieb9 / berrybrew

Perlbrew for Windows!
Other
63 stars 9 forks source link

Add option to allow `use` to start a shell other than cmd.exe #245

Closed jimbobmcgee closed 2 years ago

jimbobmcgee commented 4 years ago

Hi; just offering a possible feature request, if you are taking them...

Could you add an option to allow starting an alternative shell (e.g. PowerShell) when running berrybrew use?

I can see that you hardcode the use of cmd.exe at https://github.com/stevieb9/berrybrew/blob/master/src/berrybrew.cs#L2037 and https://github.com/stevieb9/berrybrew/blob/master/src/berrybrew.cs#L2071, and am suggesting instead allowing the user to override that via berrybrew options.

I would normally just run my shell executable inside the cmd.exe created by berrybrew but, very occasionally, some characters get mangled when I run powershell.exe. I'm hoping that having berrybrew start the shell directly will make that go away.

(Whether or not arguments to the shell invocation could be supplied as another option is bonus issue -- it might, for instance, make more sense to set the prompt using a /k argument to cmd.exe, so other shells could implement their own prompt mechanism.)

stevieb9 commented 4 years ago

I've just re-set up my environments for testing, and this interests me.

To be honest, I've only used Powershell in limited fashion over the years (I use almost exclusively Unix), so if I create a branch and make these (quite significant) infrastructural changes to the software, will you be available to test for me?

jimbobmcgee commented 4 years ago

Certainly, if you can provide a short primer for what/how you need me to test -- I haven't had the chance to make heavy use of Berrybrew yet, though, so I might not be the best candidate...