Linux: Any way to limit the battery's max charge level?

GUI tools to set hardware settings vary wildly by DE, so the option may be there, but not exposed. I set my settings in the terminal on Thinkpads.

I don’t yet have a Framework to test, but someone who does could perhaps check in /sys/class/power_supply/BAT0/, and see if there is some file that looks correct? On my Thinkpad it’s labeled charge_control_end_threshold and charge_control_start_threshold.

The former sets the peak charge percentage, the latter the minimum charge percentage to begin charging.