mirror of
https://github.com/ublue-os/bazzite.git
synced 2025-03-14 10:21:09 +00:00
Merge branch 'testing'
This commit is contained in:
commit
2215dfd14f
@ -1,26 +1,29 @@
|
||||
#!/usr/bin/bash
|
||||
set -e
|
||||
|
||||
source /etc/os-release
|
||||
|
||||
if [[ $# -eq 1 ]]; then
|
||||
case "$1" in
|
||||
"-c")
|
||||
-c)
|
||||
if [[ -f /var/ublue-update/branch ]]; then
|
||||
branch=$(cat /var/ublue-update/branch)
|
||||
else
|
||||
branch=$(cut -d ":" -f4 <<< "$(rpm-ostree status | grep -m 1 'bazzite')")
|
||||
branch=$(cut -d ":" -f4 <<< "$(rpm-ostree status --booted | grep -m 1 $VARIANT_ID)")
|
||||
fi
|
||||
|
||||
branch=${branch,,}
|
||||
case "$branch" in
|
||||
"latest" | "stable")
|
||||
# Trim and convert to lowercase
|
||||
branch=$(echo "$branch" | tr '[:upper:]' '[:lower:]' | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
||||
case $branch in
|
||||
latest|stable)
|
||||
echo rel
|
||||
exit 0
|
||||
;;
|
||||
"testing")
|
||||
testing)
|
||||
echo rc
|
||||
exit 0
|
||||
;;
|
||||
"unstable")
|
||||
unstable)
|
||||
echo main
|
||||
exit 0
|
||||
;;
|
||||
@ -33,7 +36,7 @@ if [[ $# -eq 1 ]]; then
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
"-l")
|
||||
-l)
|
||||
echo rel
|
||||
echo rc
|
||||
echo beta
|
||||
@ -41,15 +44,15 @@ if [[ $# -eq 1 ]]; then
|
||||
echo main
|
||||
exit 0
|
||||
;;
|
||||
"rel" | "latest" | "stable")
|
||||
rel|latest|stable)
|
||||
/usr/bin/pkexec /usr/libexec/ublue-update-rebase "stable"
|
||||
exit 0
|
||||
;;
|
||||
"rc" | "beta" | "testing")
|
||||
rc|beta|testing)
|
||||
/usr/bin/pkexec /usr/libexec/ublue-update-rebase "testing"
|
||||
exit 0
|
||||
;;
|
||||
"bc" | "main" | "unstable")
|
||||
bc|main|unstable)
|
||||
echo "The unstable branch has a high risk of breaking."
|
||||
echo "Do NOT use it unless you know what you are doing."
|
||||
/usr/bin/pkexec /usr/libexec/ublue-update-rebase "unstable"
|
||||
|
Loading…
x
Reference in New Issue
Block a user