-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Incompatibility with zsh-autocomplete and a transient prompt #5193
Comments
@D3SOX does this also happen without a transient prompt in your config (and restart the shell). Keyhandlers can influence this. |
You are correct, commenting out the transient prompt part makes it work again. |
I can confirm this bug also appeared on my machine after enabling transient prompt. |
@D3SOX i'll have a look, but it might as well be that we're both overriding the same function here. The internals of zsh on this front aren't well documented either I'm afraid. |
It just works fine for me |
@LiberaTeMetuMortis Can you post your config files for reference |
# yaml-language-server: $schema=https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json
version: 2
final_space: true
console_title_template: "{{ .Shell }} in {{ .Folder }}"
blocks:
- type: prompt
alignment: left
segments:
- type: session
style: diamond
foreground: p:black
background: "#9370db"
leading_diamond:
trailing_diamond:
template: " {{ if .SSHSession }}\ueba9 {{ end }}{{ .UserName }} "
- type: path
style: powerline
powerline_symbol:
foreground: p:white
background: "#9932cc"
template: " \uea83 {{ path .Path .Location }} "
properties:
style: folder
- type: git
style: powerline
powerline_symbol:
foreground: p:black
foreground_templates:
- "{{ if or (.Working.Changed) (.Staging.Changed) }}p:black{{ end }}"
- "{{ if and (gt .Ahead 0) (gt .Behind 0) }}p:white{{ end }}"
- "{{ if gt .Ahead 0 }}p:white{{ end }}"
background: p:green
background_templates:
- "{{ if or (.Working.Changed) (.Staging.Changed) }}p:yellow{{ end }}"
- "{{ if and (gt .Ahead 0) (gt .Behind 0) }}p:red{{ end }}"
- "{{ if gt .Ahead 0 }}#49416D{{ end }}"
- "{{ if gt .Behind 0 }}#7A306C{{ end }}"
template: " {{ if .UpstreamURL }}{{ url .UpstreamIcon .UpstreamURL }} {{ end }}{{ .HEAD }}{{if .BranchStatus }} {{ .BranchStatus }}{{ end }}{{ if .Working.Changed }} \uf044 {{ .Working.String }}{{ end }}{{ if .Staging.Changed }} \uf046 {{ .Staging.String }}{{ end }} "
properties:
branch_max_length: 25
fetch_status: true
fetch_upstream_icon: true
- type: root
style: powerline
powerline_symbol:
foreground: p:white
background: p:yellow
template: " \uf0e7 "
- type: status
style: diamond
foreground: p:white
background: p:blue
background_templates:
- "{{ if gt .Code 0 }}p:red{{ end }}"
leading_diamond: <transparent,background></>
trailing_diamond:
template: " {{ if gt .Code 0 }}\uf00d{{ else }}\uf00c{{ end }} "
properties:
always_enabled: true
- type: rprompt
segments:
- type: node
style: plain
foreground: p:green
background: transparent
template: "\ue718 "
properties:
display_mode: files
fetch_package_manager: false
home_enabled: false
- type: go
style: plain
foreground: p:blue
background: transparent
template: "\ue626 "
properties:
fetch_version: false
- type: python
style: plain
foreground: p:yellow
background: transparent
template: "\ue235 "
properties:
display_mode: files
fetch_version: false
fetch_virtual_env: false
- type: shell
style: plain
foreground: p:white
background: transparent
template: "in <p:blue><b>{{ .Name }}</b></> "
- type: time
style: plain
foreground: p:white
background: transparent
template: at <p:blue><b>{{ .CurrentDate | date "15:04:05" }}</b></>
transient_prompt:
foreground: p:black
background: transparent
template: "<p:purple>\ue0b6</><,p:purple> {{ .UserName }} </><p:purple,transparent>\ue0b0</> "
secondary_prompt:
foreground: p:black
background: transparent
template: "<p:yellow,transparent>\ue0b6</><,p:yellow> > </><p:yellow,transparent>\ue0b0</> "
palette:
black: "#262B44"
blue: "#4B95E9"
green: "#59C9A5"
orange: "#F07623"
red: "#D81E5B"
white: "#E0DEF4"
yellow: "#F3AE35"
purple: "#9370db" |
Posh redefines zle-line-init instead of decorating it. This makes some other zsh plugins fail if they also rely on redefining it. This commit adds a helper function to decorate any user-defined widget and use it to decorate zle-line-init. The logic in this commit is largely inspired by how the zsh-highligting plugin does the widget wrapping.
Posh redefines zle-line-init instead of decorating it. This makes some other zsh plugins fail if they also rely on redefining it. This commit adds a helper function to decorate any user-defined widget and use it to decorate zle-line-init. The logic in this commit is largely inspired by how the zsh-highligting plugin does the widget wrapping.
Posh redefines zle-line-init instead of decorating it. This makes some other zsh plugins fail if they also rely on redefining it. This commit adds a helper function to decorate any user-defined widget and use it to decorate zle-line-init. The logic in this commit is largely inspired by how the zsh-highligting plugin does the widget wrapping. This fixes issue JanDeDobbeleer#5193.
Code of Conduct
What happened?
After installing Oh my Posh I can no longer navigate zsh-autocomplete for example with the arrow keys
Theme
What OS are you seeing the problem on?
Linux
Which shell are you using?
zsh
Log output
The text was updated successfully, but these errors were encountered: