[presets] add steamos files

This commit is contained in:
Philip Mueller
2023-07-03 14:31:13 +02:00
parent e4c9ded69f
commit 689751f754
86 changed files with 14172 additions and 0 deletions

View File

@@ -0,0 +1,36 @@
#!/bin/bash
set -e
BRANCH_PATH="/var/lib/steamos-branch"
if [[ "$#" = 1 ]]; then
case "$1" in
"-c")
branch=$(cat "$BRANCH_PATH" 2> /dev/null || echo "rel")
case "$branch" in
"rel" | "rc" | "beta" | "bc" | "main")
echo "$branch"
exit 0
;;
*)
echo "unknown branch name in $BRANCH_PATH: $branch" 1>&2
exit 1
;;
esac
;;
"-l")
echo rel
echo rc
echo beta
echo bc
echo main
exit 0
;;
"rel" | "rc" | "beta" | "bc" | "main")
echo "$1" > "$BRANCH_PATH"
exit 0
;;
esac
fi
echo "Usage: steamos-select-branch <-c|-l|rel|rc|beta|bc|main>" 1>&2