-
-
Notifications
You must be signed in to change notification settings - Fork 811
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
Change in behavior of tab-completion #974
Comments
I had the same issue while using |
Hi! @KlemensE , could you specify what do you mean by "source"? |
See https://ohmyposh.dev/docs/segments/scm/git under Properties you can find This is because the autocompletion evaluates based on the global variable $GitStatus. This value comes from the Get-GitStatus function. This variable is probably not set correctly. |
For my workaround, I simply added the following to my PowerShell profile: # ... load oh-my-posh
# ... load posh-git
$Global:_ompPoshGit = $true |
I'll be honest, I don't understand how omp is involved with the tab suggestion issue. |
As I understand, it's because posh-git uses the structure that is stored in the global variable When you also use oh-my-posh at the same time, oh-my-posh is taking over the prompt rendering, and as such, it needs to update the |
@KlemensE's solution worked for me. Thanks a lot. I also cannot understand why is oh-my-posh involved in git completions, but changing that property solved my problem. |
System Details
Issue Description
I am not sure this is a posh-git issue but I could replicate it on both pwsh (with oh-my-posh) and powershell (clean)
The issue is simple: autocompletion used to be smart about files.
e.g.
If I start typing
git add <tab>
I used to be able to cycle through the dirty files and pick which one I wanted to add. Now instead it cycles through all files and directories, even.git/
This behavior has changed recently and I am trying to understand what caused it and how to revert it because it seriously affects my workflow.
The text was updated successfully, but these errors were encountered: