From eb427413ebc2eb0aefb0fef20be4a50eb7bad77d Mon Sep 17 00:00:00 2001 From: matthiasberner Date: Thu, 2 Oct 2025 22:39:19 +0200 Subject: [PATCH] =?UTF-8?q?BastilleBSD/Ports/switch-to-latest-port.sh=20hi?= =?UTF-8?q?nzugef=C3=BCgt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- BastilleBSD/Ports/switch-to-latest-port.sh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 BastilleBSD/Ports/switch-to-latest-port.sh diff --git a/BastilleBSD/Ports/switch-to-latest-port.sh b/BastilleBSD/Ports/switch-to-latest-port.sh new file mode 100644 index 0000000..33b4ea7 --- /dev/null +++ b/BastilleBSD/Ports/switch-to-latest-port.sh @@ -0,0 +1,22 @@ +#!/bin/sh +# Usage: ./switch-to-latest.sh + +JAIL="$1" + +if [ -z "$JAIL" ]; then + echo "Usage: $0 " + exit 1 +fi + +echo ">>> Switching jail '$JAIL' from quarterly to latest..." + +# Suchen & ersetzen in Repo-Dateien (falls quarterly noch drin ist) +bastille cmd "$JAIL" sh -c "sed -i '' 's|quarterly|latest|g' /etc/pkg/FreeBSD.conf /usr/local/etc/pkg/repos/FreeBSD.conf 2>/dev/null || true" + +# Repository neu laden +bastille cmd "$JAIL" pkg update -f + +# Upgrade der Pakete +#bastille cmd "$JAIL" pkg upgrade -y + +echo ">>> Jail '$JAIL' is now using latest repo."