#!/bin/bash # repetition is key in here echo 60 | sudo tee -a /sys/class/power_supply/BAT0/charge_control_end_threshold &>/dev/null echo 40 | sudo tee -a /sys/class/power_supply/BAT0/charge_control_start_threshold &>/dev/null echo 60 | sudo tee -a /sys/class/power_supply/BAT0/charge_control_end_threshold &>/dev/null echo 40 | sudo tee -a /sys/class/power_supply/BAT0/charge_control_start_threshold &>/dev/null echo 60 | sudo tee -a /sys/class/power_supply/BAT0/charge_control_end_threshold >/dev/null echo 40 | sudo tee -a /sys/class/power_supply/BAT0/charge_control_start_threshold >/dev/null