Save Battery Life (#32)
* Added parameters (also made the script more of a program). * Add additional options for unplugged devices. * Allow disabling of cron jobs and lowering of telegraf frequency through new config options. * Fix cron package name. * Fix ssh service name for Ubuntu. * Add output to the options so user knows they were switched. * Prevent some tasks when device is mobile. * Enhance and add to comments. * Add function to check flatpak app disk usage. * Add repair into flatpak commands to help clean disk space of unused apps. * Remove "Done!" output from flatpak-usage. * Go ahead and add function for purging Flatpak apps. * Few more comment changes.
This commit is contained in:
@ -16,6 +16,7 @@
|
||||
tar: tar
|
||||
microcode_amd: amd64-microcode
|
||||
microcode_intel: intel-microcode
|
||||
cron: cron
|
||||
when: ansible_pkg_mgr == "apt"
|
||||
|
||||
- name: General | Facts | Package | pacman
|
||||
@ -26,6 +27,7 @@
|
||||
tar: tar
|
||||
microcode_amd: linux-firmware
|
||||
microcode_intel: intel-ucode
|
||||
cron: cronie
|
||||
when: ansible_pkg_mgr == "pacman"
|
||||
|
||||
- name: General | Facts | Package | FreeBSD
|
||||
@ -47,6 +49,7 @@
|
||||
tar: tar
|
||||
microcode_amd: microcode_ctl
|
||||
microcode_intel: microcode_ctl
|
||||
cron: cronie
|
||||
when: ansible_pkg_mgr == "dnf"
|
||||
|
||||
|
||||
@ -140,6 +143,7 @@
|
||||
update_flatpak: |
|
||||
echo "*** Flatpak ***" &&
|
||||
sudo flatpak uninstall --unused {{ update_accept_var }} &&
|
||||
sudo flatpak repair &&
|
||||
sudo flatpak update {{ update_accept_var }} &&
|
||||
when: flatpak_exec is defined and flatpak_exec.failed is defined and not flatpak_exec.failed
|
||||
|
||||
|
@ -15,8 +15,14 @@
|
||||
acpi: acpid
|
||||
acpi_pattern: acpid
|
||||
|
||||
- name: General | Facts | Service | Linux
|
||||
- name: General | Facts | Service | Arch Linux
|
||||
set_fact:
|
||||
crond: cronie
|
||||
crond_pattern: cronie
|
||||
when: ansible_distribution == "Archlinux"
|
||||
|
||||
- name: General | Facts | Service | Ubuntu Linux
|
||||
set_fact:
|
||||
sshd: ssh
|
||||
sshd_pattern: ssh
|
||||
when: ansible_distribution == "Ubuntu"
|
||||
|
Reference in New Issue
Block a user