Include work laptop configuration in update alias

This commit is contained in:
Marko Korhonen 2022-08-03 09:41:20 +03:00
parent 6ccbf70b57
commit 5acb1dfb07
No known key found for this signature in database
GPG key ID: 911B85FBC6003FE5

View file

@ -141,7 +141,12 @@ passync() { pass git pull && pass git push && updatesecrets }
update() { update() {
all() { all() {
{%@@ if profile == "Moria" or profile == 'Mirkwood' @@%}
paru paru
{%@@ endif @@%}
{%@@ if profile == "mko-laptop" @@%}
apt
{%@@ endif @@%}
{%@@ if profile == "Moria" @@%} {%@@ if profile == "Moria" @@%}
repo repo
docker-update docker-update
@ -174,8 +179,12 @@ update() {
docker system prune -af --volumes docker system prune -af --volumes
} }
apt() {
sudo apt update && sudo apt full-upgrade -y && sudo apt autoremove -y && sudo apt autoclean -y
}
if [ $# -eq 0 ]; then if [ $# -eq 0 ]; then
1=base 1=all
fi fi
case "$1" in case "$1" in
@ -185,14 +194,21 @@ update() {
plugins) plugins)
plugins plugins
;; ;;
{%@@ if profile == "Moria" @@%}
docker) docker)
docker-update docker-update
;; ;;
repo) repo)
repo repo
;; ;;
{%@@ endif @@%}
{%@@ if profile == "mko-laptop" @@%}
apt)
apt
;;
{%@@ endif @@%}
*) *)
paru all
;; ;;
esac esac
} }