Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Bash Shell support (partially fixes #44) #61

Merged
merged 2 commits into from
Apr 12, 2018

Conversation

xiaoyinl
Copy link
Contributor

This PR adds a "Start Bash Shell" to menu, which opens Bash on Windows, if it's installed.

While I totally agree with the comments in #44 that it is better to make this configurable, I don't have enough Windows GUI knowledge to write a configuration dialog. So far I only implemented a menu item "Start Bash Shell", which launches bash.exe if it exists. I want to share this code so that, if you want, you can develop on top of this PR.

This PR adds a "Start Bash Shell" to menu, which opens Bash on Windows,
if it's installed.
@NazmusLabs
Copy link
Contributor

I'd love this to be included in the interm until a configuration system is developed. Having three most used shells isn't a bad idea.

I'm, curious though, if this throws an exception in older versions of Windows that predates WSL

@xiaoyinl
Copy link
Contributor Author

xiaoyinl commented Apr 10, 2018

@NazmusLabs It won't throw an exception if WSL doesn't exist. It just won't do anything if it can't find bash.exe.

@NazmusLabs
Copy link
Contributor

@xiaoyinl Yeah, I realized that after I checked the code. :)

I did see that you did hard code the system32 folder so that the 32 bit version also works. I'm curious how this affects OSes prior to XP 64 bit, which I don't believe knows what sysdrive is, but I could be wrong.

@xiaoyinl
Copy link
Contributor Author

@NazmusLabs I am not sure if it understands it or not. But that doesn't matter in this case, because if it doesn't understand, PathFileExists will return false, which is correct anyway, because Bash only runs on Windows 10 x64.

@craigwi craigwi merged commit 3a8c17c into microsoft:master Apr 12, 2018
@xiaoyinl xiaoyinl deleted the bash branch April 12, 2018 04:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants