mirror of
https://github.com/theupriser/steamify-cachyos.git
synced 2026-10-03 17:41:58 +02:00
feat: "Boot into" is a sub-option of the conversion
Shown indented under the SteamOS conversion, and only while it's ticked.
This commit is contained in:
1 parent
0f503dd112
commit
4895de3a46
4 files changed
+25
-10
No files matched your search
@@ -133,7 +133,9 @@ gamescope and the Plasma desktop. Primary target: the Valve Steam Machine
|
|||||||
pacman hook can't run pacman), which triggers DKMS's install hook. The module creates
|
pacman hook can't run pacman), which triggers DKMS's install hook. The module creates
|
||||||
`/sys/class/leds/valve-leds*`.
|
`/sys/class/leds/valve-leds*`.
|
||||||
- `boot` ("Boot into: [gamescope] / desktop") is a choice row, not a
|
- `boot` ("Boot into: [gamescope] / desktop") is a choice row, not a
|
||||||
checkbox: on = desktop. It needs `gaming` (ticking it ticks gaming,
|
checkbox: on = desktop. It's a sub-option of the conversion: `menu_visible`
|
||||||
|
only shows it (indented, `└`) while `gaming` is ticked, so menu numbers
|
||||||
|
after it shift by one when the conversion is unticked. It needs `gaming` (ticking it ticks gaming,
|
||||||
unticking gaming unticks it) and is never preselected (`NO_PRESELECT`), so
|
unticking gaming unticks it) and is never preselected (`NO_PRESELECT`), so
|
||||||
the conversion boots into gamescope by default. Desktop is
|
the conversion boots into gamescope by default. Desktop is
|
||||||
`steamify-boot-desktop.service`, ordered `Before=` the login managers:
|
`steamify-boot-desktop.service`, ordered `Before=` the login managers:
|
||||||
|
|||||||
+3
-1
@@ -7,7 +7,7 @@ one per merged pull request.
|
|||||||
|
|
||||||
## 0.10.0 - 2026-09-24
|
## 0.10.0 - 2026-09-24
|
||||||
|
|
||||||
- **feat: Boot into gamescope or the desktop**
|
- `0f503dd` **feat: Boot into gamescope or the desktop**
|
||||||
- New menu row under the conversion, "Boot into: [gamescope] / desktop";
|
- New menu row under the conversion, "Boot into: [gamescope] / desktop";
|
||||||
gamescope stays the default and is never changed on a first run.
|
gamescope stays the default and is never changed on a first run.
|
||||||
- Desktop: `steamify-boot-desktop.service` sets the autologin session to
|
- Desktop: `steamify-boot-desktop.service` sets the autologin session to
|
||||||
@@ -16,6 +16,8 @@ one per merged pull request.
|
|||||||
it. Choosing desktop turns the conversion on; turning the conversion off
|
it. Choosing desktop turns the conversion on; turning the conversion off
|
||||||
resets it to gamescope.
|
resets it to gamescope.
|
||||||
- The later menu items move down one (BIOS is now 8 on a Steam Machine).
|
- The later menu items move down one (BIOS is now 8 on a Steam Machine).
|
||||||
|
- **feat: "Boot into" is a sub-option of the conversion**
|
||||||
|
- Shown indented under the SteamOS conversion, and only while it's ticked.
|
||||||
|
|
||||||
## 0.9.1 - 2026-09-24 (#10)
|
## 0.9.1 - 2026-09-24 (#10)
|
||||||
|
|
||||||
|
|||||||
@@ -14,9 +14,10 @@ Everything you turn off is put back the way it was.
|
|||||||
Desktop** in Steam works and so does going back (the **Return to Gaming
|
Desktop** in Steam works and so does going back (the **Return to Gaming
|
||||||
Mode** icon on the desktop), you're back in gaming mode after a restart,
|
Mode** icon on the desktop), you're back in gaming mode after a restart,
|
||||||
and Steam's on-screen keyboard (Steam + X) also works on the desktop.
|
and Steam's on-screen keyboard (Steam + X) also works on the desktop.
|
||||||
2. **Boot into: [gamescope] / desktop** - where the PC starts. Gamescope
|
2. **Boot into: [gamescope] / desktop** - a sub-option of 1, shown under it
|
||||||
(gaming mode) is the default; choose desktop to start in KDE Plasma
|
while it's ticked: where the PC starts. Gamescope (gaming mode) is the
|
||||||
instead, with Return to Gaming Mode one double-click away. (Needs 1.)
|
default; choose desktop to start in KDE Plasma instead, with Return to
|
||||||
|
Gaming Mode one double-click away.
|
||||||
3. **SteamOS theme** - the Vapor look for the desktop (CachyOS's
|
3. **SteamOS theme** - the Vapor look for the desktop (CachyOS's
|
||||||
`cachyos-vapor` package).
|
`cachyos-vapor` package).
|
||||||
4. **Steam Deck/Machine icons** - Steam Deck button icons in gaming mode.
|
4. **Steam Deck/Machine icons** - Steam Deck button icons in gaming mode.
|
||||||
|
|||||||
+15
-5
@@ -34,6 +34,13 @@ component_available() {
|
|||||||
|
|
||||||
is_action() { [[ " ${ACTIONS[*]} " == *" $1 "* ]]; }
|
is_action() { [[ " ${ACTIONS[*]} " == *" $1 "* ]]; }
|
||||||
|
|
||||||
|
menu_visible() {
|
||||||
|
# Shown in the menu. "Boot into" is a sub-option of the conversion: only
|
||||||
|
# while the conversion is ticked.
|
||||||
|
component_available "$1" || return 1
|
||||||
|
[[ "$1" != boot || "${WANTED[gaming]:-0}" == 1 ]]
|
||||||
|
}
|
||||||
|
|
||||||
component_selectable() {
|
component_selectable() {
|
||||||
# Greyed out and not tickable when it has nothing to do.
|
# Greyed out and not tickable when it has nothing to do.
|
||||||
case "$1" in
|
case "$1" in
|
||||||
@@ -76,7 +83,7 @@ show_menu() {
|
|||||||
printf " ${c_bold}%-3s %-6s %-6s %s${c_reset}\n" "#" "Now" "Want" "Component"
|
printf " ${c_bold}%-3s %-6s %-6s %s${c_reset}\n" "#" "Now" "Want" "Component"
|
||||||
MENU_ITEMS=()
|
MENU_ITEMS=()
|
||||||
for c in "${COMPONENTS[@]}"; do
|
for c in "${COMPONENTS[@]}"; do
|
||||||
component_available "$c" || continue
|
menu_visible "$c" || continue
|
||||||
i=$((i + 1)); MENU_ITEMS[$i]=$c
|
i=$((i + 1)); MENU_ITEMS[$i]=$c
|
||||||
# Pad the plain word, then colour it: colour codes would count as width.
|
# Pad the plain word, then colour it: colour codes would count as width.
|
||||||
now="off"; [[ "${CURRENT[$c]}" == 1 ]] && now="on"
|
now="off"; [[ "${CURRENT[$c]}" == 1 ]] && now="on"
|
||||||
@@ -89,7 +96,7 @@ show_menu() {
|
|||||||
now="gaming"; [[ "${CURRENT[boot]}" == 1 ]] && now="desk"
|
now="gaming"; [[ "${CURRENT[boot]}" == 1 ]] && now="desk"
|
||||||
[[ "${CURRENT[gaming]}" == 1 ]] || now="-"
|
[[ "${CURRENT[gaming]}" == 1 ]] || now="-"
|
||||||
want="gaming"; [[ "${WANTED[boot]}" == 1 ]] && want="desk"
|
want="gaming"; [[ "${WANTED[boot]}" == 1 ]] && want="desk"
|
||||||
printf " %-3s %-6s %-6s %s\n" "$i" "$now" "$want" "$(boot_choice "${WANTED[boot]}")"
|
printf " %-3s %-6s %-6s └ %s\n" "$i" "$now" "$want" "$(boot_choice "${WANTED[boot]}")"
|
||||||
elif component_selectable "$c"; then
|
elif component_selectable "$c"; then
|
||||||
printf " %-3s %b %-6s %s\n" "$i" "$now" "$want" "${LABEL[$c]}"
|
printf " %-3s %b %-6s %s\n" "$i" "$now" "$want" "${LABEL[$c]}"
|
||||||
else
|
else
|
||||||
@@ -122,7 +129,7 @@ draw_menu_tui() {
|
|||||||
echo
|
echo
|
||||||
MENU_ITEMS=()
|
MENU_ITEMS=()
|
||||||
for c in "${COMPONENTS[@]}"; do
|
for c in "${COMPONENTS[@]}"; do
|
||||||
component_available "$c" || continue
|
menu_visible "$c" || continue
|
||||||
MENU_ITEMS[$i]=$c
|
MENU_ITEMS[$i]=$c
|
||||||
box="[ ]"; [[ "${WANTED[$c]}" == 1 ]] && box="[${c_green}x${c_reset}]"
|
box="[ ]"; [[ "${WANTED[$c]}" == 1 ]] && box="[${c_green}x${c_reset}]"
|
||||||
state=" (now: off)"; [[ "${CURRENT[$c]}" == 1 ]] && state=" (now: ${c_green}on${c_reset})"
|
state=" (now: off)"; [[ "${CURRENT[$c]}" == 1 ]] && state=" (now: ${c_green}on${c_reset})"
|
||||||
@@ -130,10 +137,11 @@ draw_menu_tui() {
|
|||||||
line="$box ${LABEL[$c]}"
|
line="$box ${LABEL[$c]}"
|
||||||
if [[ "$c" == boot ]]; then
|
if [[ "$c" == boot ]]; then
|
||||||
# A choice rather than a checkbox; Space switches it.
|
# A choice rather than a checkbox; Space switches it.
|
||||||
|
# Indented under the conversion, whose sub-option it is.
|
||||||
line="$(boot_choice "${WANTED[boot]}")"
|
line="$(boot_choice "${WANTED[boot]}")"
|
||||||
line="${line/\[/[${c_green}}"; line="${line/\]/${c_reset}]}"
|
line=" └ ${line/\[/[${c_green}}"; line="${line/\]/${c_reset}]}"
|
||||||
state=" (now: gamescope)"; [[ "${CURRENT[boot]}" == 1 ]] && state=" (now: desktop)"
|
state=" (now: gamescope)"; [[ "${CURRENT[boot]}" == 1 ]] && state=" (now: desktop)"
|
||||||
[[ "${CURRENT[gaming]}" == 1 ]] || state=" (with the SteamOS conversion)"
|
[[ "${CURRENT[gaming]}" == 1 ]] || state=""
|
||||||
fi
|
fi
|
||||||
if ! component_selectable "$c"; then
|
if ! component_selectable "$c"; then
|
||||||
# Greyed out: nothing to do (e.g. BIOS already up to date).
|
# Greyed out: nothing to do (e.g. BIOS already up to date).
|
||||||
@@ -160,6 +168,8 @@ run_menu_tui() {
|
|||||||
while true; do
|
while true; do
|
||||||
draw_menu_tui "$cursor"
|
draw_menu_tui "$cursor"
|
||||||
count=${#MENU_ITEMS[@]}
|
count=${#MENU_ITEMS[@]}
|
||||||
|
# The list shrinks when the conversion (and its sub-option) is unticked.
|
||||||
|
if (( cursor >= count )); then cursor=$(( count - 1 )); draw_menu_tui "$cursor"; fi
|
||||||
IFS= read -rsn1 key
|
IFS= read -rsn1 key
|
||||||
if [[ "$key" == $'\e' ]]; then
|
if [[ "$key" == $'\e' ]]; then
|
||||||
IFS= read -rsn2 -t 0.05 rest
|
IFS= read -rsn2 -t 0.05 rest
|
||||||
|
|||||||
Reference in new issue
Block a user