updater.sh aktualisiert
This commit is contained in:
23
updater.sh
23
updater.sh
@@ -1,16 +1,31 @@
|
|||||||
#!/usr/bin/env fish
|
#!/bin/bash
|
||||||
|
|
||||||
paru -Syu --ignore simulationcraft-git --noconfirm
|
IGNORE="$HOME/.local/state/leanderUpdater/ignored_packages.txt"
|
||||||
|
|
||||||
|
# Überprüfen, ob die Datei existiert
|
||||||
|
if [ ! -f "$IGNORE" ]; then
|
||||||
|
# Datei anlegen und aktuellen Zeitpunkt speichern
|
||||||
|
install -Dm644 /dev/null "$HOME/.local/state/leanderUpdater/ignored_packages.txt"
|
||||||
|
fi
|
||||||
|
|
||||||
|
paru -Sy archlinux-keyring --noconfirm
|
||||||
|
paru -Syu $(xargs -I {} echo --ignore {} < $IGNORE) --noconfirm
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
echo "Update abgeschlossen. Bitte Enter drücken, um das Terminal zu schließen..."
|
echo "Update abgeschlossen. Bitte Enter drücken, um das Terminal zu schließen..."
|
||||||
|
|
||||||
# Pfad zur Datei
|
# Pfad zur Datei
|
||||||
set FILE "last_update.txt"
|
FILE="$HOME/.local/state/leanderUpdater/last_update.txt"
|
||||||
|
|
||||||
|
# Überprüfen, ob die Datei existiert
|
||||||
|
if [ ! -f "$FILE" ]; then
|
||||||
|
# Datei anlegen und aktuellen Zeitpunkt speichern
|
||||||
|
install -Dm644 /dev/null "$HOME/.local/state/leanderUpdater/last_update.txt"
|
||||||
|
fi
|
||||||
|
|
||||||
# Aktueller Zeitpunkt
|
# Aktueller Zeitpunkt
|
||||||
truncate -s 0 "$FILE"
|
truncate -s 0 "$FILE"
|
||||||
set current_time $(date +%s)
|
current_time=$(date +%s)
|
||||||
echo "$current_time" > "$FILE"
|
echo "$current_time" > "$FILE"
|
||||||
|
|
||||||
read -p ""
|
read -p ""
|
||||||
|
|||||||
Reference in New Issue
Block a user