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

Code clean up #740

Merged
merged 2 commits into from
Mar 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions DistroLauncher/DistributionInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ HRESULT DistributionInfo::ChangeDefaultUserInWslConf(const std::wstring_view use
_swprintf_p(commandLine, _countof(commandLine),
L"if [ $(grep -c \"\\[user\\]\" /etc/wsl.conf) -eq \"0\" ]; then echo -e \"\\n[user]\\ndefault=%1$s\">>/etc/wsl.conf; else sed -i \"s/\\(default=\\)\\(.*\\)/\\1%1$s/\" /etc/wsl.conf ; fi",
std::wstring(userName).c_str());
MessageBoxW(nullptr, commandLine, L"Hola", MB_OK);


if (const auto hr = g_wslApi.WslLaunchInteractive(commandLine, true, &exitCode); FAILED(hr) || exitCode != 0)
{
Expand Down
8 changes: 8 additions & 0 deletions DistroLauncher/DistroLauncher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,14 @@ int wmain(const int argc, const wchar_t* argv[])
// Install the distribution if it is not already.
const auto installOnly = arguments.size() > 0 && arguments[0] == ARG_INSTALL;
auto hr = S_OK;
/*

if (!g_wslApi.WslIsDistributionRegistered())
{
g_wslApi.SetDistributionName(L"Pengwin");
}
*/

if (!g_wslApi.WslIsDistributionRegistered())
{
// If the "--root" option is specified, do not create a user account.
Expand Down
2 changes: 1 addition & 1 deletion Pengwin/Package.appxmanifest
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<Identity
Name="WhitewaterFoundryLtd.Co.16571368D6CFF"
Publisher="CN=9879127B-9E92-4DE5-9C32-0B1F09F95DCF"
Version="22.3.1.0" />
Version="22.3.2.0" />

<Properties>
<DisplayName>Pengwin</DisplayName>
Expand Down