Skip to content

fix(cli): window options getting leaked into subsequent buffers - #347

Open
amadeus wants to merge 1 commit into
folke:mainfrom
amadeus:option-fix
Open

fix(cli): window options getting leaked into subsequent buffers#347
amadeus wants to merge 1 commit into
folke:mainfrom
amadeus:option-fix

Conversation

@amadeus

@amadeus amadeus commented Jul 25, 2026

Copy link
Copy Markdown

Description

Performing :edit from the sidekick window left the new buffer with the terminal styling (no number column, fixed width, etc). The styling is now buffer-local so Neovim restores your own options, and sidekick lets go of the window when another buffer takes it over.

One small additional change in this PR is that using 0 for width/height of the window allows the buffer to abide by neovim's normal buffer sizing logic. A comment was added to the config to document this.

AI was used to generate the code, however I reviewed it to the best of my knowledge to ensure I could understand what it was doing and how it functioned.

Related Issue(s)

Fixes #294

Screenshots

CleanShot.2026-07-25.at.14.25.27.mp4

…e cli window. Fixes folke#294

Performing :edit from the sidekick window left the new buffer with the
terminal styling (no number column, fixed width, etc). The styling is
now buffer-local so Neovim restores your own options, and sidekick lets
go of the window when another buffer takes it over.
@github-actions github-actions Bot added the size/xl Extra large PR (100+ lines changed) label Jul 25, 2026
@amadeus amadeus changed the title Fix window options getting leaked into subsequent buffers fix: window options getting leaked into subsequent buffers Jul 25, 2026
@amadeus amadeus changed the title fix: window options getting leaked into subsequent buffers fix(cli): window options getting leaked into subsequent buffers Jul 25, 2026
float = {
focusable = true,
relative = "editor",
style = "minimal",

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"minimal" was ultimately removed here because all the other window options already matched except for the lack of foldcolumn = 0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/xl Extra large PR (100+ lines changed)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: window-local terminal options leak into :edit-replaced buffers

1 participant