-
Notifications
You must be signed in to change notification settings - Fork 8.1k
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
Remove carriage return from WSL distribution names. #1169
Conversation
Pull in updates 07 Jun 19
@@ -534,7 +534,11 @@ void CascadiaSettings::_AppendWslProfiles(std::vector<TerminalApp::Profile>& pro | |||
if (wlinestream) | |||
{ | |||
std::wstring distName; | |||
std::getline(wlinestream, distName, L' '); | |||
std::getline(wlinestream, distName, L'\r'); | |||
size_t firstChar = distName.find_first_of(L"( "); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd definitely leave a comment referring back to #1168 about how we need to make sure to stop the name at a parentheses, since "(default)" might be included in the output
Co-Authored-By: Mike Griese <migrie@microsoft.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unless github is acting up, there's some minor spacing issues here. Otherwise, this looks great! Thanks!
Removed spacing. Co-Authored-By: Dustin L. Howett (MSFT) <duhowett@microsoft.com>
Removed Spacing Co-Authored-By: Dustin L. Howett (MSFT) <duhowett@microsoft.com>
Thanks for fixing this! |
Summary of the Pull Request
Checks the Distribution name for
\r
and removes it if necessary.References
#1168
PR Checklist
Detailed Description of the Pull Request / Additional comments
One line to check for and remove any carriage return characters.
Validation Steps Performed
I've installed a second distribution and tested this to ensure that it now functions properly.