gitfetch icon indicating copy to clipboard operation
gitfetch copied to clipboard

suggestion: --force-(component) to force component displaying

Open Matars opened this issue 1 year ago • 4 comments

same way that --no-(component) force hides, --force-(component) should force render.

I think these two working together can give lots of power to the user - especially when there is automatic layouting based on terminal size.

Matars avatar Oct 21 '25 16:10 Matars

But how should you handle it if the terminal isnt big enough to show the component?

Zeviraty avatar Oct 21 '25 16:10 Zeviraty

based on terminal size.

There are three different layouts

https://github.com/Matars/gitfetch/blob/ac109ffa250bead3c26f23adfa5aedfd00932189/src/gitfetch/display.py#L197

based on the terminals height and width I try to guess best option - however its not always great.

I will be creating docs regarding the auto layout, its limitations and hardcoded values. I really like the auto layouting however some edge cases are annoying (that's why --no- and --force- are helpful)

Matars avatar Oct 21 '25 16:10 Matars

but if you --force-(insert every component here) and the terminal is too small what will happen?

Zeviraty avatar Oct 21 '25 16:10 Zeviraty

overflow, however it give you ability to force when it thinks there is an overflow but actually there is space.

--force and --no of course cannot be called together on the same component

Matars avatar Oct 21 '25 17:10 Matars