From b8d9f6442a51a452312d98a63cb25c80d23b4294 Mon Sep 17 00:00:00 2001 From: Eugene Pankov Date: Mon, 20 Apr 2020 15:35:15 +0200 Subject: [PATCH] re-fixed #517 --- terminus-terminal/src/services/terminal.service.ts | 2 +- terminus-terminal/src/shells/wsl.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/terminus-terminal/src/services/terminal.service.ts b/terminus-terminal/src/services/terminal.service.ts index 2fc9c35d..2b6cfbca 100644 --- a/terminus-terminal/src/services/terminal.service.ts +++ b/terminus-terminal/src/services/terminal.service.ts @@ -49,7 +49,7 @@ export class TerminalService { } getProfileID (profile: Profile): string { - return slugify(profile.name).toLowerCase() + return slugify(profile.name, { remove: /[:.]/g }).toLowerCase() } async getProfileByID (id: string): Promise { diff --git a/terminus-terminal/src/shells/wsl.ts b/terminus-terminal/src/shells/wsl.ts index 86763f9e..696873f5 100644 --- a/terminus-terminal/src/shells/wsl.ts +++ b/terminus-terminal/src/shells/wsl.ts @@ -91,8 +91,9 @@ export class WSLShellProvider extends ShellProvider { const wslVersion = childKey.Flags.value & 8 ? 2 : 1 const name = childKey.DistributionName.value const fsBase = wslVersion === 2 ? `\\\\wsl$\\${name}` : childKey.BasePath.value as string + '\\rootfs' + const slug = slugify(name, { remove: /[:.]/g }) const shell: Shell = { - id: `wsl-${slugify(name)}`, + id: `wsl-${slug}`, name: `WSL / ${name}`, command: wslPath, args: ['-d', name],