updateall/scripts : remaniement

This commit is contained in:
Ahurac 2024-04-12 09:39:27 +02:00
parent 895726a7d6
commit 7536613376
8 changed files with 18 additions and 25 deletions

View file

@ -1,5 +1,7 @@
#!/bin/sh -ex #!/usr/bin/env sh
[ "$(whoami)" != root ] && exec sudo "$0" "$@" [ "$(whoami)" != root ] && exec sudo -- "$0" "$@"
set -x -e
apt-get clean apt-get clean
apt-get update apt-get update
apt-file update apt-file update

View file

@ -1,8 +1,7 @@
#!/usr/bin/env sh #!/usr/bin/env sh
set -x -e
[ "$(whoami)" != root ] && exec sudo -- "$0" "$@" [ "$(whoami)" != root ] && exec sudo -- "$0" "$@"
set -e -x
aura -Cc 0 aura -Cc 0
aura -Cv aura -Cv
aura -Fy aura -Fy

View file

@ -1,5 +0,0 @@
#!/bin/sh -ex
apt clean
pkg update
pkg upgrade
apt autopurge -y

View file

@ -1,5 +1,4 @@
#!/usr/bin/env sh #!/usr/bin/env sh
cd ~/docker || exit cd ~/docker || exit
for i in *; do (set -e for i in *; do (set -e

View file

@ -1,2 +1,3 @@
#!/bin/sh -ex #!/usr/bin/env sh
sudo waydroid upgrade set -x
exec sudo waydroid upgrade

View file

@ -1,2 +1,3 @@
#!/bin/sh -ex #!/usr/bin/env sh
yabridgectl sync set -x
exec yabridgectl sync

View file

@ -1,25 +1,20 @@
#!/bin/sh -x #!/usr/bin/env sh
[ -z "$SSH_AGENT_PID" ] && exec ssh-agent -- "$0" "$@"
if [ -z "$SSH_AGENT_PID" ]; then
exec ssh-agent "$0" "$@"
fi
ssh-add ssh-add
update_repo() { update_repo() {
cd "$1" || return cd -- "$1" || return
printf 'Updating repository \033[1m%s\033[0m...\n' "$1" printf 'Updating repository \033[1m%s\033[0m...\n' "$1"
git pull git pull
} }
cd ~/git || exit cd ~/git || exit
set +x
for i in *; do for i in *; do
while [ "$(jobs -p | wc -l)" -ge 4 ]; do while [ "$(jobs -p | wc -l)" -ge 4 ]; do
sleep 1 sleep 1
done done
update_repo "$i" & update_repo "$i" &
done done
wait wait

View file

@ -1,2 +1,3 @@
#!/bin/sh -x #!/usr/bin/env sh
nvim +PaqSync set -x
exec nvim +PaqSync