1
0
Fork 0
forked from ahurac/dotfiles

Correction : les scripts de updateall qui font appel à sudo sont ré-exécutés pour être root

This commit is contained in:
Hippolyte Chauvin 2023-07-28 10:18:41 +02:00
parent 4f818076b7
commit e130dfe569
2 changed files with 6 additions and 4 deletions

View file

@ -1,5 +1,6 @@
#!/bin/sh
sudo apt-get update
sudo apt-get upgrade
sudo apt-get autoremove
[ "$USER" != root ] && exec sudo "$0" "$@"
apt-get update
apt-get upgrade
apt-get autoremove

View file

@ -1,3 +1,4 @@
#!/bin/sh
sudo docker images --format '{{.Repository}}' | xargs -L 1 sudo docker pull
[ "$USER" != root ] && exec "$0" "$@"
docker images --format '{{.Repository}}' | xargs -L 1 docker pull