JanDeDobbeleer / oh-my-posh

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

& was unexpected at this time. #4796

Closed Nerd10000 closed 7 months ago

Nerd10000 commented 7 months ago

Code of Conduct

What happened?

I tried this command or script and I got this.

Theme

None

What OS are you seeing the problem on?

Windows

Which shell are you using?

cmd

Log output

[DEBUG] 17:41:41.417 shell.go:Getenv:325 → NO DATA
[TRACE] 17:41:41.469 shell.go:Getenv(TERM_PROGRAM) - 52.079ms
[DEBUG] 17:41:41.469 shell.go:Getenv:325 → C:\Users\Dragon\AppData\Local
[TRACE] 17:41:41.469 shell.go:Getenv(LOCALAPPDATA) - 0s
[TRACE] 17:41:41.469 shell_windows.go:CachePath() - 0s
[DEBUG] 17:41:41.469 shell.go:Getenv:325 → NO DATA
[TRACE] 17:41:41.469 shell.go:Getenv(POSH_THEME) - 0s
[DEBUG] 17:41:41.469 shell.go:resolveConfigPath:245 → No config set, fallback to default config
[TRACE] 17:41:41.469 shell.go:resolveConfigPath() - 0s
[TRACE] 17:41:41.469 shell.go:Init() - 52.079ms
[TRACE] 17:41:41.469 shell.go:Flags() - 0s
[DEBUG] 17:41:41.469 config.go:loadConfig:126 → no config file specified, using default
[TRACE] 17:41:41.469 config.go:loadConfig() - 505.5µs
[TRACE] 17:41:41.469 shell.go:Flags() - 0s
[DEBUG] 17:41:41.469 shell.go:Getenv:325 → NO DATA
[TRACE] 17:41:41.469 shell.go:Getenv(OMP_CACHE_DISABLED) - 40µs
[TRACE] 17:41:41.469 shell_windows.go:WindowsRegistryKeyValue(HKEY_CURRENT_USER\Software\Microsoft\Windows\DWM\ColorizationColor) - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[TRACE] 17:41:41.469 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.469 shell_windows.go:WindowsRegistryKeyValue:217 → ColorizationColor(DWORD): 0xC40078D7
[DEBUG] 17:41:41.469 shell.go:Shell:593 → no shell name provided in flags, trying to detect it
[DEBUG] 17:41:41.476 shell.go:Shell:601 → process name: cmd.exe
[TRACE] 17:41:41.476 shell.go:Shell() - 7.2359ms
[DEBUG] 17:41:41.476 shell.go:Getenv:325 → NO DATA
[TRACE] 17:41:41.476 shell.go:Getenv(POSH_SHELL_VERSION) - 0s
[DEBUG] 17:41:41.476 debug.go:PrintDebug:22 → Segment: Title
[DEBUG] 17:41:41.476 text.go:Render:70 → Rendering template: {{ .Shell }} in {{ .Folder }}
[TRACE] 17:41:41.477 shell_windows.go:Root() - 539.9µs
[TRACE] 17:41:41.477 shell.go:Shell() - 0s
[TRACE] 17:41:41.477 shell.go:StatusCodes() - 0s
[TRACE] 17:41:41.477 shell_windows.go:IsWsl() - 0s
[DEBUG] 17:41:41.477 shell.go:TemplateCache:774 → environment: [=C:=C:\Users\Dragon =ExitCode=00000000 ALLUSERSPROFILE=C:\ProgramData APPDATA=C:\Users\Dragon\AppData\Roaming CommonProgramFiles=C:\Program Files\Common Files CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files CommonProgramW6432=C:\Program Files\Common Files COMPUTERNAME=DESKTOP-O5T2D7M ComSpec=C:\WINDOWS\system32\cmd.exe DriverData=C:\Windows\System32\Drivers\DriverData HOMEDRIVE=C: HOMEPATH=\Users\Dragon LOCALAPPDATA=C:\Users\Dragon\AppData\Local LOGONSERVER=\\DESKTOP-O5T2D7M NUMBER_OF_PROCESSORS=4 OneDrive=C:\Users\Dragon\OneDrive OS=Windows_NT Path=C:\VulkanSDK\1.3.280.0\Bin;C:\Program Files\Common Files\Oracle\Java\javapath;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files (x86)\VMware\VMware Player\bin\;C:\Program Files\Eclipse Adoptium\jdk-21.0.1.12-hotspot\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\NVIDIA Corporation\NVIDIA NvDLISR;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\dotnet\;C:\Program Files\nodejs\;C:\Program Files\Git\cmd;C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit\;C:\Program Files\apache-maven-3.8.8\bin;C:\Users\Dragon\.cargo\bin;C:\Users\Dragon\AppData\Local\Microsoft\WindowsApps;C:\Users\Dragon\AppData\Local\Programs\Microsoft VS Code\bin;C:\Program Files (x86)\Nmap;C:\PyCharm\PyCharm Community Edition 2023.3.2\bin;;C:\Users\Dragon\.dotnet\tools;C:\Users\Dragon\AppData\Roaming\npm;C:\Users\Dragon\AppData\Local\GitHubDesktop\bin;C:\Program Files (x86)\FreeArc\bin;C:\msys64\ucrt64\bin;;C:\Users\Dragon\AppData\Local\Programs\oh-my-posh\bin PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC POSH_INSTALLER=winget POSH_THEMES_PATH=C:\Users\Dragon\AppData\Local\Programs\oh-my-posh\themes PROCESSOR_ARCHITECTURE=AMD64 PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 58 Stepping 9, GenuineIntel PROCESSOR_LEVEL=6 PROCESSOR_REVISION=3a09 ProgramData=C:\ProgramData ProgramFiles=C:\Program Files ProgramFiles(x86)=C:\Program Files (x86) ProgramW6432=C:\Program Files PROMPT=$P$G PSModulePath=C:\Program Files\WindowsPowerShell\Modules;C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules PUBLIC=C:\Users\Public PyCharm Community Edition=C:\PyCharm\PyCharm Community Edition 2023.3.2\bin; SESSIONNAME=Console SystemDrive=C: SystemRoot=C:\WINDOWS TEMP=C:\Users\Dragon\AppData\Local\Temp TMP=C:\Users\Dragon\AppData\Local\Temp USERDOMAIN=DESKTOP-O5T2D7M USERDOMAIN_ROAMINGPROFILE=DESKTOP-O5T2D7M USERNAME=Dragon USERPROFILE=C:\Users\Dragon VK_SDK_PATH=C:\VulkanSDK\1.3.280.0 VULKAN_SDK=C:\VulkanSDK\1.3.280.0 windir=C:\WINDOWS WSLENV=WT_SESSION:WT_PROFILE_ID: WT_PROFILE_ID={0caa0dad-35be-5f56-a8ff-afceeeaa6101} WT_SESSION=feee654d-6114-4e84-99d8-3a0670752b2e __PSLockDownPolicy=0]
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.477 shell.go:Pwd:355 → C:\Users\Dragon
[TRACE] 17:41:41.477 shell.go:Pwd() - 0s
[DEBUG] 17:41:41.477 shell_windows.go:58 → C:\Users\Dragon
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.477 shell.go:User:493 → Dragon
[TRACE] 17:41:41.477 shell.go:User() - 0s
[DEBUG] 17:41:41.477 shell.go:Host:505 → DESKTOP-O5T2D7M
[TRACE] 17:41:41.477 shell.go:Host() - 0s
[TRACE] 17:41:41.477 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.477 shell.go:Getenv:325 → NO DATA
[TRACE] 17:41:41.477 shell.go:Getenv(SHLVL) - 0s
[TRACE] 17:41:41.477 shell.go:TemplateCache() - 539.9µs
[DEBUG] 17:41:41.477 shell.go:Getenv:325 → NO DATA
[TRACE] 17:41:41.477 shell.go:Getenv(POSH_CURSOR_LINE) - 0s
[DEBUG] 17:41:41.477 shell.go:Getenv:325 → NO DATA
[TRACE] 17:41:41.477 shell.go:Getenv(POSH_CURSOR_COLUMN) - 0s
[TRACE] 17:41:41.477 shell.go:Flags() - 0s
[TRACE] 17:41:41.477 shell.go:Flags() - 0s
[TRACE] 17:41:41.477 shell.go:Shell() - 0s
[TRACE] 17:41:41.477 shell.go:Shell() - 0s
[TRACE] 17:41:41.478 shell.go:Flags() - 0s
[TRACE] 17:41:41.478 shell.go:Flags() - 0s
[TRACE] 17:41:41.478 shell.go:Pwd() - 0s
[DEBUG] 17:41:41.478 shell_windows.go:58 → C:\Users\Dragon
[TRACE] 17:41:41.478 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.478 segment.go:SetEnabled:529 → Segment: Session
[DEBUG] 17:41:41.478 properties.go:GetString:28 → {{ .Code }}
[TRACE] 17:41:41.478 shell.go:Pwd() - 0s
[DEBUG] 17:41:41.478 shell.go:Getenv:325 → NO DATA
[DEBUG] 17:41:41.478 shell_windows.go:58 → C:\Users\Dragon
[TRACE] 17:41:41.478 shell.go:GOOS() - 0s
[TRACE] 17:41:41.478 shell.go:Flags() - 0s
[DEBUG] 17:41:41.478 shell.go:Getenv:325 → NO DATA
[DEBUG] 17:41:41.478 segment.go:SetEnabled:529 → Segment: Status
[TRACE] 17:41:41.478 shell.go:Getenv(SSH_CLIENT) - 0s
[TRACE] 17:41:41.478 shell.go:StatusCodes() - 0s
[TRACE] 17:41:41.478 shell.go:TemplateCache() - 0s
[DEBUG] 17:41:41.478 text.go:Render:70 → Rendering template: {{ .Code }}
[TRACE] 17:41:41.478 shell.go:Flags() - 0s
[TRACE] 17:41:41.478 shell.go:Pwd() - 0s
[TRACE] 17:41:41.478 shell.go:Pwd() - 0s
[DEBUG] 17:41:41.478 shell_windows.go:58 → C:\Users\Dragon
[TRACE] 17:41:41.478 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.478 segment.go:SetEnabled:529 → Segment: Root
[DEBUG] 17:41:41.478 shell_windows.go:58 → C:\Users\Dragon
[TRACE] 17:41:41.478 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.478 segment.go:SetEnabled:529 → Segment: Git
[TRACE] 17:41:41.478 shell.go:GOOS() - 0s
[TRACE] 17:41:41.478 shell_windows.go:Root() - 0s
[TRACE] 17:41:41.478 shell.go:Flags() - 0s
[DEBUG] 17:41:41.478 shell.go:Getenv:325 → C:\Users\Dragon\AppData\Local
[TRACE] 17:41:41.478 shell.go:Getenv(LOCALAPPDATA) - 0s
[TRACE] 17:41:41.478 shell.go:Pwd() - 0s
[DEBUG] 17:41:41.478 shell_windows.go:58 → C:\Users\Dragon
[TRACE] 17:41:41.478 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.478 segment.go:SetEnabled:529 → Segment: Path
[TRACE] 17:41:41.478 shell.go:Pwd() - 0s
[TRACE] 17:41:41.478 shell.go:Shell() - 0s
[TRACE] 17:41:41.478 shell.go:Shell() - 0s
[DEBUG] 17:41:41.478 properties.go:GetBool:22 → mapped_locations_enabled: true
[TRACE] 17:41:41.479 shell.go:TemplateCache() - 0s
[DEBUG] 17:41:41.478 properties.go:GetString:28 → 
[DEBUG] 17:41:41.479 properties.go:GetString:28 → 
[DEBUG] 17:41:41.479 shell_windows.go:58 → C:\Users\Dragon
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.479 properties.go:GetString:28 → ~
[DEBUG] 17:41:41.479 properties.go:GetKeyValueMap:46 → mapped_locations: map[]
[TRACE] 17:41:41.479 shell.go:PathSeparator() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[DEBUG] 17:41:41.479 properties.go:GetBool:22 → always_enabled: true
[TRACE] 17:41:41.479 shell.go:TemplateCache() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:PathSeparator() - 0s
[TRACE] 17:41:41.479 shell.go:PathSeparator() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:PathSeparator() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:PathSeparator() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:GOOS() - 0s
[TRACE] 17:41:41.479 shell.go:PathSeparator() - 0s
[TRACE] 17:41:41.479 shell.go:Pwd() - 0s
[TRACE] 17:41:41.479 shell_windows.go:IsWsl() - 0s
[TRACE] 17:41:41.479 shell.go:StackCount() - 0s
[DEBUG] 17:41:41.480 win32_windows.go:isWriteable:299 → not current user or in group
[DEBUG] 17:41:41.480 win32_windows.go:isWriteable:303 → current user is member of S-1-5-32-544
[DEBUG] 17:41:41.480 win32_windows.go:isWriteable:311 ↓
    WRITE_DAC
    WRITE_OWNER
    SYNCHRONIZE
    DELETE
    READ_CONTROL
[DEBUG] 17:41:41.480 win32_windows.go:isWriteable:313 → user has write access
[TRACE] 17:41:41.480 shell_windows.go:DirIsWritable() - 1.3336ms
[TRACE] 17:41:41.480 shell.go:TemplateCache() - 0s
[DEBUG] 17:41:41.505 shell.go:CommandPath:545 → C:\Program Files\Git\cmd\git.exe
[TRACE] 17:41:41.505 shell.go:CommandPath(git.exe) - 27.9596ms
[TRACE] 17:41:41.505 shell.go:HasCommand(git.exe) - 27.9596ms
[TRACE] 17:41:41.505 shell.go:Pwd() - 0s
[ERROR] 17:41:41.507 shell.go:HasParentFilePath:689 → CreateFile .git: A rendszer nem találja a megadott fájlt.
[TRACE] 17:41:41.507 shell.go:HasParentFilePath(.git) - 1.6496ms
[DEBUG] 17:41:41.507 properties.go:GetBool:22 → fetch_bare_info: false
[DEBUG] 17:41:41.507 text.go:Render:70 → Rendering template:  {{ if gt .Code 0 }}{{ else }}{{ end }}
[DEBUG] 17:41:41.507 text.go:Render:70 → Rendering template:  {{ if .SSHSession }} {{ end }}{{ .UserName }}
[DEBUG] 17:41:41.507 text.go:Render:70 → Rendering template:   {{ path .Path .Location }}
[TRACE] 17:41:41.507 shell.go:TemplateCache() - 0s
[TRACE] 17:41:41.507 shell.go:TemplateCache() - 0s
[TRACE] 17:41:41.507 shell.go:TemplateCache() - 0s
[TRACE] 17:41:41.507 shell.go:Shell() - 0s
[TRACE] 17:41:41.507 shell.go:Shell() - 0s
[TRACE] 17:41:41.507 shell.go:Shell() - 0s
[DEBUG] 17:41:41.507 text.go:Render:70 → Rendering template: diamond
[DEBUG] 17:41:41.508 text.go:Render:70 → Rendering template: powerline
[DEBUG] 17:41:41.508 text.go:Render:70 → Rendering template: powerline
[DEBUG] 17:41:41.508 text.go:Render:70 → Rendering template: powerline
[DEBUG] 17:41:41.508 text.go:Render:70 → Rendering template: {{ if gt .Code 0 }}p:red{{ end }}
[TRACE] 17:41:41.508 shell.go:TemplateCache() - 0s
[DEBUG] 17:41:41.508 text.go:Render:70 → Rendering template: diamond
[TRACE] 17:41:41.508 shell.go:Shell() - 0s
[TRACE] 17:41:41.508 shell.go:Shell() - 0s
[TRACE] 17:41:41.508 shell.go:Shell() - 0s
[TRACE] 17:41:41.508 shell.go:Flags() - 0s
[TRACE] 17:41:41.508 shell.go:Shell() - 0s
[TRACE] 17:41:41.508 shell.go:Shell() - 0s
[DEBUG] 17:41:41.508 shell.go:Getenv:325 → C:\Users\Dragon\AppData\Local
[TRACE] 17:41:41.508 shell.go:Getenv(LOCALAPPDATA) - 0s
[TRACE] 17:41:41.508 shell_windows.go:CachePath() - 539.7µs
[TRACE] 17:41:41.508 shell.go:Flags() - 0s
JanDeDobbeleer commented 7 months ago

@Nerd10000 I believe some information is missing.