bos-settings moves to git.breadway.dev/Breadway/bos-settings (full history preserved via git-filter-repo) so its release cadence is decoupled from BOS's own. breadhelp takes its place as this repo's workspace member: a GTK4 onboarding/help center replacing the old bos-welcome/bos-keybinds bash scripts with searchable guides, an interactive keybind viewer (sourced from the new keybinds.toml, not parsed out of hyprland.lua or hardcoded), a troubleshooting wizard with one-click fixes, and a proper first-run tour. bos-netcheck extracts bos-welcome's network-check half, which still needs to run every login independent of breadhelp's own first-run gating. hyprland.lua's keybinds/settings/monitors/autostart are now JSON-driven (binds.json/settings.json/monitors.json/autostart.json) with every loader pcall-wrapped and falling back to hardcoded defaults per field on bad or missing config, so bread* apps (bos-settings' new editors, and breadhelp's keybind viewer) can read/write this config without ever being able to leave the compositor unable to start. CI's package.yml now builds breadhelp instead of bos-settings on tag push; bos-settings needs its own equivalent workflow in its new repo (not yet set up).
35 lines
1.6 KiB
Bash
Executable file
35 lines
1.6 KiB
Bash
Executable file
#!/bin/bash
|
|
# Every-login network connectivity check. Split out of the old bos-welcome
|
|
# script, which conflated this with one-time onboarding (now breadhelp's
|
|
# job) — this half must keep running unconditionally on every login, before
|
|
# any GUI toolkit is worth spinning up, and must never be gated by a marker.
|
|
set -u
|
|
|
|
# Never run in the live/installer session — only on an installed system.
|
|
[[ "$(id -un)" == "liveuser" ]] && exit 0
|
|
|
|
# A fresh install usually boots with no connection (Wi-Fi isn't configured
|
|
# during install), and the first `bos-update`/pacman run then fails with
|
|
# confusing DNS/"could not resolve host" errors. If NetworkManager reports
|
|
# we're not fully online, open nmtui so the user can join a network before
|
|
# anything else. Best-effort: missing nmcli/nmtui/kitty, or the user quitting
|
|
# nmtui, must never block the rest of login.
|
|
command -v nmcli &>/dev/null || exit 0
|
|
|
|
conn="$(nmcli networking connectivity check 2>/dev/null)"
|
|
# NetworkManager may still be associating right at compositor start — give it
|
|
# a few short retries before concluding we're actually offline, so a machine
|
|
# with working Wi-Fi doesn't get a spurious nmtui popup.
|
|
tries=0
|
|
while [[ "$conn" != "full" && "$tries" -lt 3 ]]; do
|
|
sleep 1
|
|
conn="$(nmcli networking connectivity check 2>/dev/null)"
|
|
tries=$((tries + 1))
|
|
done
|
|
|
|
if [[ "$conn" != "full" ]]; then
|
|
notify-send -u normal "BOS" "No internet yet — opening network setup so updates work." 2>/dev/null || true
|
|
if command -v nmtui &>/dev/null; then
|
|
kitty --class bos-netsetup --title "Connect to a network" -- nmtui connect 2>/dev/null || true
|
|
fi
|
|
fi
|