mirror of
https://github.com/ublue-os/bazzite.git
synced 2025-01-30 03:32:36 +00:00
feat(just): update recipe to edit tuned default profile using ppd.conf (#907)
* feat(just): update recipe to change tuned default profile in ppd.conf * chore(just): change wording on the powerprofile dialog
This commit is contained in:
parent
b60b1e621f
commit
eed757d500
@ -140,8 +140,13 @@ configure-powerprofile ACTION="":
|
||||
echo " Use 'balanced' to select Balanced"
|
||||
exit 0
|
||||
elif [ "$OPTION" == "" ]; then
|
||||
# Cleanup old method
|
||||
if [ -f "~/.config/autostart/bazzite-powersave.desktop" ]; then
|
||||
rm ~/.config/autostart/bazzite-powersave.desktop
|
||||
fi
|
||||
# New method from here on
|
||||
echo "${bold}Power profile configuration${normal}"
|
||||
echo "This lets you set the default power profile for when the desktop loads."
|
||||
echo "This lets you set the default power profile."
|
||||
echo "We do not recommend changing this from ${b}Balanced${n} if you use this device primarily for gaming!"
|
||||
echo "If you have any performance or audio related issues..."
|
||||
echo "${invert}${b}Please test with the default power profile set to Balanced${n} before reporting!"
|
||||
@ -151,19 +156,11 @@ configure-powerprofile ACTION="":
|
||||
fi
|
||||
if [[ "${OPTION,,}" =~ powersave ]]; then
|
||||
echo "Setting default powerprofile to ${b}Powersave${n}"
|
||||
bash -c 'cat << PPD > ~/.config/autostart/bazzite-powersave.desktop
|
||||
[Desktop Entry]
|
||||
Exec=/usr/bin/bazzite-powersave
|
||||
Icon=dialog-scripts
|
||||
Name=bazzite-powersave
|
||||
Type=Application
|
||||
PPD'
|
||||
sudo sed -iE 's/default=(.+)/default=powersave/' /etc/tuned/ppd.conf
|
||||
bazzite-powersave
|
||||
elif [[ "${OPTION,,}" =~ balanced ]]; then
|
||||
echo "Setting default powerprofile to ${b}Balanced${n}"
|
||||
if [ -f "~/.config/autostart/bazzite-powersave.desktop" ]; then
|
||||
rm ~/.config/autostart/bazzite-powersave.desktop
|
||||
fi
|
||||
sudo sed -iE 's/default=(.+)/default=balanced/' /etc/tuned/ppd.conf
|
||||
bazzite-powersave 0
|
||||
fi
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user