diff --git a/TerminalDocs/tutorials/shell-integration.md b/TerminalDocs/tutorials/shell-integration.md index 9f060124..276a3026 100644 --- a/TerminalDocs/tutorials/shell-integration.md +++ b/TerminalDocs/tutorials/shell-integration.md @@ -123,9 +123,9 @@ function prompt { if ($Global:__LastHistoryId -ne -1) { if ($LastHistoryEntry.Id -eq $Global:__LastHistoryId) { # Don't provide a command line or exit code if there was no history entry (eg. ctrl+c, enter on no command) - $out += "`e]133;D`a" + $out += "$([char]0x1b)]133;D$([char]07)" } else { - $out += "`e]133;D;$gle`a" + $out += "$([char]0x1b)]133;D;$gle$([char]07)" } } @@ -133,16 +133,16 @@ function prompt { $loc = $($executionContext.SessionState.Path.CurrentLocation); # Prompt started - $out += "`e]133;A$([char]07)"; + $out += "$([char]0x1b)]133;A$([char]07)"; # CWD - $out += "`e]9;9;`"$loc`"$([char]07)"; + $out += "$([char]0x1b)]9;9;`"$loc`"$([char]07)"; # (your prompt here) $out += "PWSH $loc$('>' * ($nestedPromptLevel + 1)) "; # Prompt ended, Command started - $out += "`e]133;B$([char]07)"; + $out += "$([char]0x1b)]133;B$([char]07)"; $Global:__LastHistoryId = $LastHistoryEntry.Id