JanDeDobbeleer / oh-my-posh

The most customisable and low-latency cross platform/shell prompt renderer
https://ohmyposh.dev
MIT License
16.19k stars 2.3k forks source link

git-bash + win11 terminal = corrupted history #4998

Closed kyxap closed 1 month ago

kyxap commented 1 month ago

Code of Conduct

What happened?

If I'm trying to list the history in terminal it's became corrupted.

Steps reproduce:

Example: image

Theme

export POSH_THEMES_PATH="$HOME/AppData/Local/Programs/oh-my-posh/themes"
eval "$(oh-my-posh --init --shell bash --config $POSH_THEMES_PATH/gruvbox.omp.json)"

# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.

if [ -f ~/.bash_aliases ]; then
    . ~/.bash_aliases
fi

What OS are you seeing the problem on?

Windows

Which shell are you using?

bash

Log output

Version: 19.30.0

Shell: bash (5.2.26(1)-release)

Prompt:

   ~ 

Segments:

ConsoleTitle(true)                        -   1 ms
Os(true)                                  -   1 ms
Path(true)                                -   1 ms
Git(false)                                -   2 ms
Go(false)                                 -   0 ms
Julia(false)                              -   0 ms
Python(false)                             -   0 ms
Ruby(false)                               -   1 ms
Azfunc(false)                             -   0 ms
Aws(false)                                -   0 ms
Root(false)                               -   0 ms

Run duration: 16.316ms

Cache path: C:\Users\user_name\AppData\Local\oh-my-posh

Config path: C:/Users/user_name/AppData/Local/Programs/oh-my-posh/themes/gruvbox.omp.json

Logs:

[DEBUG] 18:35:52.711 shell.go:Getenv:325 → NO DATA
[TRACE] 18:35:52.712 shell.go:Getenv(TERM_PROGRAM) - 2.1248ms
[DEBUG] 18:35:52.713 shell.go:Getenv:325 → C:\Users\user_name\AppData\Local
[TRACE] 18:35:52.713 shell.go:Getenv(LOCALAPPDATA) - 0s
[TRACE] 18:35:52.713 shell_windows.go:CachePath() - 0s
[DEBUG] 18:35:52.713 shell.go:Getenv:325 → C:/Users/user_name/AppData/Local/Programs/oh-my-posh/themes/gruvbox.omp.json
[TRACE] 18:35:52.713 shell.go:Getenv(POSH_THEME) - 0s
[DEBUG] 18:35:52.713 shell.go:Shell:593 → no shell name provided in flags, trying to detect it
[DEBUG] 18:35:52.720 shell.go:Shell:601 → process name: bash.exe
[TRACE] 18:35:52.720 shell.go:Shell() - 6.8628ms
[DEBUG] 18:35:52.720 shell.go:resolveConfigPath:259 → Cygwin detected, using full path for config
[TRACE] 18:35:52.720 shell.go:resolveConfigPath() - 7.3956ms
[TRACE] 18:35:52.720 shell.go:Init() - 10.049ms
[TRACE] 18:35:52.720 shell.go:Flags() - 0s
[TRACE] 18:35:52.722 config.go:loadConfig() - 515.5µs
[TRACE] 18:35:52.722 shell.go:Flags() - 0s
[DEBUG] 18:35:52.722 shell.go:Getenv:325 → NO DATA
[TRACE] 18:35:52.722 shell.go:Getenv(OMP_CACHE_DISABLED) - 0s
[TRACE] 18:35:52.722 shell_windows.go:WindowsRegistryKeyValue(HKEY_CURRENT_USER\Software\Microsoft\Windows\DWM\ColorizationColor) - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[TRACE] 18:35:52.722 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.722 shell_windows.go:WindowsRegistryKeyValue:217 → ColorizationColor(DWORD): 0xC4000000
[TRACE] 18:35:52.722 shell.go:Shell() - 0s
[DEBUG] 18:35:52.722 shell.go:Getenv:325 → 5.2.26(1)-release
[TRACE] 18:35:52.722 shell.go:Getenv(POSH_SHELL_VERSION) - 0s
[DEBUG] 18:35:52.722 debug.go:PrintDebug:22 → Segment: Title
[DEBUG] 18:35:52.723 text.go:Render:71 → Rendering template: {{ .Folder }}
[TRACE] 18:35:52.723 shell_windows.go:Root() - 0s
[TRACE] 18:35:52.723 shell.go:Shell() - 0s
[TRACE] 18:35:52.723 shell.go:StatusCodes() - 0s
[TRACE] 18:35:52.723 shell_windows.go:IsWsl() - 0s
[DEBUG] 18:35:52.723 shell.go:TemplateCache:774 → environment: [3DVPATH=C:\AMD\Chipset_Software\Binaries\3D_V-Cache_Performance_Optimizer_Driver\ ALLUSERSPROFILE=C:\ProgramData AMDRMPATH=C:\Program Files\AMD\RyzenMaster\ APPDATA=C:\Users\user_name\AppData\Roaming COMMONPROGRAMFILES=C:\Program Files\Common Files COMPUTERNAME=PC-BIG COMSPEC=C:\Windows\system32\cmd.exe CONDA_PROMPT_MODIFIER=false ChocolateyInstall=C:\ProgramData\chocolatey ChocolateyLastPathUpdate=133593174146815042 ChocolateyToolsLocation=C:\tools CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files CommonProgramW6432=C:\Program Files\Common Files D3DGEARPATH=d:\games\iracing\d3dgear DriverData=C:\Windows\System32\Drivers\DriverData EXEPATH=C:\Program Files\Git\bin GOPATH=C:\Users\user_name\go HOME=C:\Users\user_name HOMEDRIVE=C: HOMEPATH=\Users\user_name JAVA_HOME=C:\Program Files\Amazon Corretto\jdk17.0.9_8 LOCALAPPDATA=C:\Users\user_name\AppData\Local LOGONSERVER=\\PC-BIG MSYS=disable_pcon MSYSTEM=MINGW64 NUMBER_OF_PROCESSORS=16 OS=Windows_NT OneDrive=C:\Users\user_name\OneDrive PATH=C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\bin;C:\Users\user_name\bin;C:\Python312\Scripts\;C:\Python312\;C:\Program Files (x86)\Razer Chroma SDK\bin;C:\Program Files\Razer Chroma SDK\bin;C:\Program Files (x86)\Razer\ChromaBroadcast\bin;C:\Program Files\Razer\ChromaBroadcast\bin;C:\Program Files\Amazon Corretto\jdk17.0.9_8\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\ProgramData\chocolatey\bin;C:\Program Files (x86)\oh-my-posh\bin;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\dotnet\;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;d:\games\iracing\d3dgear;C:\Program Files\mvndaemon\maven-mvnd-0.9.0-windows-amd64\bin;C:\Windows\system32\config\systemprofile\AppData\Local\Microsoft\WindowsApps;C:\Program Files\WireGuard\;C:\Program Files\PowerShell\7\;C:\Program Files\Calibre2\;C:\Program Files\Go\bin;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;C:\Program Files\Docker\Docker\resources\bin;C:\Program Files\Git\cmd;C:\Users\user_name\AppData\Local\Microsoft\WindowsApps;C:\Users\user_name\AppData\Local\Programs\oh-my-posh\bin;C:\Users\user_name\.dotnet\tools;C:\Program Files (x86)\Nmap;C:\Users\user_name\AppData\Roaming\Python\Python312\Scripts;C:\Users\user_name\Downloads\PhoenixSuit_V1.10\PhoenixSuit_V1.10\;C:\Users\user_name\AppData\Local\Programs\Ollama;C:\ProgramData\chocolatey\lib\mingw\tools\install\mingw64\bin;C:\Users\user_name\go\bin;C:\Users\user_name\AppData\Local\Programs\Microsoft VS Code\bin PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY;.PYW PLINK_PROTOCOL=ssh POSH_INSTALLER=manual POSH_PID=897 POSH_SHELL_VERSION=5.2.26(1)-release POSH_THEME=C:/Users/user_name/AppData/Local/Programs/oh-my-posh/themes/gruvbox.omp.json POSH_THEMES_PATH=C:/Users/user_name/AppData/Local/Programs/oh-my-posh/themes POWERLINE_COMMAND=oh-my-posh POWERSHELL_DISTRIBUTION_CHANNEL=MSI:Windows 10 Home PROCESSOR_ARCHITECTURE=AMD64 PROCESSOR_IDENTIFIER=AMD64 Family 25 Model 97 Stepping 2, AuthenticAMD PROCESSOR_LEVEL=25 PROCESSOR_REVISION=6102 PROGRAMFILES=C:\Program Files PS1=\[\]\[\]  \[\]\[\]\[\]\[\]\[\]\[\] ~ \[\]\[\]\[\]\[\]  PSModulePath=C:\Program Files\WindowsPowerShell\Modules;C:\Windows\system32\WindowsPowerShell\v1.0\Modules PUBLIC=C:\Users\Public PWD=C:/Users/user_name PhoenixPath=C:\Users\user_name\Downloads\PhoenixSuit_V1.10\PhoenixSuit_V1.10\ ProgramData=C:\ProgramData ProgramFiles(x86)=C:\Program Files (x86) ProgramW6432=C:\Program Files SESSIONNAME=Console SHLVL=1 SYSTEMDRIVE=C: SYSTEMROOT=C:\Windows TEMP=C:\Users\user_name\AppData\Local\Temp TERM=xterm-256color TMP=C:\Users\user_name\AppData\Local\Temp USERDOMAIN=PC-BIG USERDOMAIN_ROAMINGPROFILE=PC-BIG USERNAME=user_name USERPROFILE=C:\Users\user_name WINDIR=C:\Windows WSLENV=WT_SESSION:WT_PROFILE_ID: WT_PROFILE_ID={fcf6856c-1a1e-45be-83cb-b493cad16034} WT_SESSION=674de8ca-9789-4119-857d-4656863c26b2 _=C:/Users/user_name/AppData/Local/Programs/oh-my-posh/bin/oh-my-posh asl.log=Destination=file]
[TRACE] 18:35:52.723 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.724 shell.go:Pwd:355 → C:\Users\user_name
[TRACE] 18:35:52.724 shell.go:Pwd() - 524.2µs
[DEBUG] 18:35:52.724 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.724 shell.go:User:493 → user_name
[TRACE] 18:35:52.724 shell.go:User() - 0s
[DEBUG] 18:35:52.724 shell.go:Host:505 → PC-BIG
[TRACE] 18:35:52.724 shell.go:Host() - 0s
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.724 shell.go:Getenv:325 → 1
[TRACE] 18:35:52.724 shell.go:Getenv(SHLVL) - 0s
[TRACE] 18:35:52.724 shell.go:TemplateCache() - 524.2µs
[DEBUG] 18:35:52.724 shell.go:Getenv:325 → NO DATA
[TRACE] 18:35:52.724 shell.go:Getenv(POSH_CURSOR_LINE) - 0s
[DEBUG] 18:35:52.724 shell.go:Getenv:325 → NO DATA
[TRACE] 18:35:52.724 shell.go:Getenv(POSH_CURSOR_COLUMN) - 0s
[TRACE] 18:35:52.724 shell.go:Flags() - 0s
[TRACE] 18:35:52.724 shell.go:Flags() - 0s
[TRACE] 18:35:52.724 shell.go:Shell() - 0s
[TRACE] 18:35:52.724 shell.go:Shell() - 0s
[TRACE] 18:35:52.724 shell.go:Flags() - 0s
[TRACE] 18:35:52.724 shell.go:Flags() - 0s
[TRACE] 18:35:52.724 shell.go:Pwd() - 0s
[TRACE] 18:35:52.724 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.724 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.724 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.724 segment.go:SetEnabled:535 → Segment: Root
[TRACE] 18:35:52.724 shell.go:Flags() - 0s
[DEBUG] 18:35:52.724 segment.go:SetEnabled:535 → Segment: Os
[TRACE] 18:35:52.724 shell_windows.go:Root() - 0s
[TRACE] 18:35:52.724 shell.go:Flags() - 0s
[TRACE] 18:35:52.724 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.724 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.724 segment.go:SetEnabled:535 → Segment: Ruby
[TRACE] 18:35:52.724 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.725 properties.go:GetStringArray:52 → extensions: [*.rb Rakefile Gemfile]
[DEBUG] 18:35:52.725 properties.go:GetStringArray:52 → folders: []
[DEBUG] 18:35:52.725 properties.go:GetBool:22 → home_enabled: false
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.725 shell.go:Flags() - 0s
[TRACE] 18:35:52.725 shell.go:TemplateCache() - 0s
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[TRACE] 18:35:52.725 shell.go:Flags() - 0s
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:Flags() - 0s
[DEBUG] 18:35:52.725 segment.go:SetEnabled:535 → Segment: Path
[TRACE] 18:35:52.725 shell.go:Flags() - 0s
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[TRACE] 18:35:52.725 shell.go:Flags() - 0s
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[TRACE] 18:35:52.725 shell.go:Shell() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:Shell() - 0s
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.725 segment.go:SetEnabled:535 → Segment: Azfunc
[TRACE] 18:35:52.725 shell.go:Flags() - 0s
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.725 properties.go:GetString:28 → files
[DEBUG] 18:35:52.725 properties.go:GetStringArray:52 → folders: []
[DEBUG] 18:35:52.725 properties.go:GetBool:22 → home_enabled: false
[DEBUG] 18:35:52.725 segment.go:SetEnabled:535 → Segment: Julia
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[DEBUG] 18:35:52.725 properties.go:GetStringArray:52 → extensions: [*.jl]
[DEBUG] 18:35:52.725 properties.go:GetStringArray:52 → folders: []
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[DEBUG] 18:35:52.725 properties.go:GetBool:22 → home_enabled: false
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.725 segment.go:SetEnabled:535 → Segment: Aws
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[DEBUG] 18:35:52.725 properties.go:GetBool:22 → mapped_locations_enabled: true
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.725 properties.go:GetString:28 → 
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.725 properties.go:GetBool:22 → display_default: false
[DEBUG] 18:35:52.725 properties.go:GetString:28 → 
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.725 shell.go:Getenv:325 → NO DATA
[TRACE] 18:35:52.725 shell.go:Getenv(AWS_VAULT) - 0s
[DEBUG] 18:35:52.725 segment.go:SetEnabled:535 → Segment: Go
[DEBUG] 18:35:52.725 segment.go:SetEnabled:535 → Segment: Python
[DEBUG] 18:35:52.725 shell.go:Getenv:325 → NO DATA
[TRACE] 18:35:52.725 shell.go:Getenv(AWS_DEFAULT_PROFILE) - 0s
[DEBUG] 18:35:52.725 shell.go:Getenv:325 → NO DATA
[DEBUG] 18:35:52.725 properties.go:GetStringArray:52 → extensions: [*.py *.ipynb pyproject.toml venv.bak]
[DEBUG] 18:35:52.725 properties.go:GetStringArray:52 → folders: [.venv venv virtualenv venv-win pyenv-win]
[DEBUG] 18:35:52.725 properties.go:GetBool:22 → home_enabled: false
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[DEBUG] 18:35:52.725 shell.go:Getenv:325 → NO DATA
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.725 properties.go:GetKeyValueMap:46 → mapped_locations: map[]
[TRACE] 18:35:52.725 shell.go:Getenv(AWS_REGION) - 0s
[TRACE] 18:35:52.725 shell.go:PathSeparator() - 0s
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[DEBUG] 18:35:52.725 shell.go:Getenv:325 → NO DATA
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:Getenv(AWS_DEFAULT_REGION) - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.725 shell.go:Getenv:325 → NO DATA
[DEBUG] 18:35:52.725 segment.go:SetEnabled:535 → Segment: Git
[TRACE] 18:35:52.725 shell.go:Getenv(AWS_CONFIG_FILE) - 0s
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[DEBUG] 18:35:52.725 shell.go:Getenv:325 → C:\Users\user_name\AppData\Local
[TRACE] 18:35:52.725 shell.go:Getenv(LOCALAPPDATA) - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:PathSeparator() - 0s
[TRACE] 18:35:52.725 shell.go:PathSeparator() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:PathSeparator() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:PathSeparator() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:GOOS() - 0s
[TRACE] 18:35:52.725 shell.go:PathSeparator() - 0s
[DEBUG] 18:35:52.725 properties.go:GetString:28 → NO DATA
[DEBUG] 18:35:52.725 shell_windows.go:58 → C:\Users\user_name
[TRACE] 18:35:52.725 shell.go:PathSeparator() - 0s
[TRACE] 18:35:52.725 shell.go:Pwd() - 0s
[TRACE] 18:35:52.725 shell_windows.go:IsWsl() - 0s
[TRACE] 18:35:52.725 shell.go:StackCount() - 0s
[ERROR] 18:35:52.725 shell.go:FileContent:463 → open C:\Users\user_name/.aws/config: The system cannot find the path specified.
[TRACE] 18:35:52.725 shell.go:FileContent(C:\Users\user_name/.aws/config) - 0s
[DEBUG] 18:35:52.726 shell.go:CommandPath:545 → C:\Program Files\Git\mingw64\bin\git.exe
[TRACE] 18:35:52.726 shell.go:CommandPath(git.exe) - 519.4µs
[TRACE] 18:35:52.726 shell.go:HasCommand(git.exe) - 519.4µs
[TRACE] 18:35:52.726 shell.go:Pwd() - 0s
[DEBUG] 18:35:52.726 win32_windows.go:isWriteable:299 → not current user or in group
[DEBUG] 18:35:52.726 win32_windows.go:isWriteable:303 → current user is member of S-1-5-32-544
[DEBUG] 18:35:52.726 win32_windows.go:isWriteable:311 ↓
    WRITE_DAC
    WRITE_OWNER
    SYNCHRONIZE
    DELETE
    READ_CONTROL
[DEBUG] 18:35:52.726 win32_windows.go:isWriteable:313 → user has write access
[TRACE] 18:35:52.726 shell_windows.go:DirIsWritable() - 519.4µs
[TRACE] 18:35:52.726 shell.go:TemplateCache() - 0s
[ERROR] 18:35:52.727 shell.go:HasParentFilePath:689 → CreateFile .git: The system cannot find the file specified.
[TRACE] 18:35:52.727 shell.go:HasParentFilePath(.git) - 533.6µs
[DEBUG] 18:35:52.727 properties.go:GetBool:22 → fetch_bare_info: false
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: {{ if .WSL }}WSL at{{ end }} {{.Icon}}
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template:  {{ .Path }}
[TRACE] 18:35:52.727 shell.go:TemplateCache() - 0s
[TRACE] 18:35:52.727 shell.go:TemplateCache() - 0s
[TRACE] 18:35:52.727 shell.go:Shell() - 0s
[TRACE] 18:35:52.727 shell.go:Shell() - 0s
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[DEBUG] 18:35:52.727 text.go:Render:71 → Rendering template: powerline
[TRACE] 18:35:52.727 shell.go:Shell() - 0s
[TRACE] 18:35:52.727 shell.go:Shell() - 0s
[TRACE] 18:35:52.727 shell.go:Flags() - 0s
[TRACE] 18:35:52.727 shell.go:Shell() - 0s
[TRACE] 18:35:52.727 shell.go:Shell() - 0s
[DEBUG] 18:35:52.727 shell.go:Getenv:325 → C:\Users\user_name\AppData\Local
[TRACE] 18:35:52.727 shell.go:Getenv(LOCALAPPDATA) - 0s
[TRACE] 18:35:52.727 shell_windows.go:CachePath() - 0s
[TRACE] 18:35:52.727 shell.go:Flags() - 0s

using git-bash 2.45.2

lewis-yeung commented 1 month ago

Confirmed the bug which can be reproduced on my PC in Windows Terminal, but not in the integrated terminal of VS Code. Seems to be a bug in Windows Terminal.

JanDeDobbeleer commented 1 month ago

I'll have a look today, be aware the support I give for git bash is limited as that shell is a bit of a hack.

kyxap commented 1 month ago

any recommendation on what to use with bash support? I remembered that for some reason WSL did not work for some of my case

JanDeDobbeleer commented 1 month ago

@kyxap if you want a modern shell, have a look at nushell.

JanDeDobbeleer commented 1 month ago

@lewis-yeung @kyxap I can't reproduce this on my Win11, not with Windows Terminal or with the preview build. I do have shell integrations disabled though. Pretty sure this is a Windows terminal bug.