Prompt does not shrink when -max-width is specfied
fenprace opened this issue · comments
Describe the bug
Prompt does not shrink for a given -max-width value.
To Reproduce
Steps to reproduce the behavior:
powerline-go -max-width 50
Expected behavior
Expect 1 or 2 segments are hidden and the printed out prompt takes no more than 50% of the width of the window.
Environment
- OS: macOS 11.1
- Architecture: x86_64
- Shell: fish 3.1.2
Additional context
My prompt settings are as following. But the -max-width
does not work in prompt either.
function fish_prompt
powerline-go -error $status -modules cwd,git,root -cwd-mode dironly -max-width 50
end
I can confirm this same behavior with powerline-go
1.20.0 on Fedora 33, with Bash as the shell.
The issue seems to be from PR #251, which mistakenly assumes that the flag max-width
is instead max-width-percentage
.
I have the fix working locally, and I'm about to open up a pull request fixing this! (Which will be linked below)