mirror of
https://github.com/DeeJanuz/frametop.git
synced 2026-10-06 08:00:09 +02:00
Fix installed service and launcher paths; wait for the pointer helper
The service and menu-entry templates still pointed at the old frametop/ subfolder, so the pointer helper, input relay, and settings apps couldn't start after a clean install. The pointer helper's install step also failed when the service was still starting after 3 s; it now waits up to 20 s and doesn't abort the installer. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
d439bc3f25
commit
983773edbd
7 files changed
+12
-10
No files matched your search
@@ -1,7 +1,7 @@
|
||||
# Template: the installer replaces @REPO@ with the repo path on the Frame.
|
||||
[Unit]
|
||||
Description=Frametop pointer helper: the universal 3D mouse (cursor, collision, ft_pointer driver)
|
||||
Documentation=file://@REPO@/frametop/README.md
|
||||
Documentation=file://@REPO@/README.md
|
||||
# Needs SteamVR's IPC; it starts and stops with SteamVR.
|
||||
After=steamvr.service frametop-input-relay.service
|
||||
PartOf=steamvr.service
|
||||
@@ -10,7 +10,7 @@ PartOf=steamvr.service
|
||||
# Runs in the dev container (built there against its libraries). The helper process
|
||||
# lives in the container, so clean it up explicitly around distrobox enter.
|
||||
ExecStartPre=-/usr/bin/pkill -x ft-pointer
|
||||
ExecStart=%h/.local/bin/distrobox enter dev -- @REPO@/frametop/pointer/helper/build/ft-pointer
|
||||
ExecStart=%h/.local/bin/distrobox enter dev -- @REPO@/pointer/helper/build/ft-pointer
|
||||
ExecStopPost=-/usr/bin/pkill -x ft-pointer
|
||||
Restart=on-failure
|
||||
RestartSec=3
|
||||
|
||||
@@ -14,8 +14,10 @@ case ${1:-status} in
|
||||
"$root/scripts/sync.sh" >/dev/null
|
||||
fill_template "$root/pointer/helper/$unit" | on_frame "mkdir -p ~/.config/systemd/user && cat > ~/.config/systemd/user/$unit"
|
||||
"$frame" --host "set -e; pkill -x ft-pointer || true
|
||||
systemctl --user daemon-reload; systemctl --user enable --now $unit; sleep 3
|
||||
systemctl --user is-active $unit; tail -n 3 /dev/null; journalctl --user -u $unit --no-pager -o cat -n 3" ;;
|
||||
systemctl --user daemon-reload; systemctl --user enable --now $unit
|
||||
# It comes up once SteamVR runs (it starts with it); distrobox enter takes a few seconds.
|
||||
for i in \$(seq 20); do systemctl --user is-active --quiet $unit && break; sleep 1; done
|
||||
echo \"$unit: \$(systemctl --user is-active $unit)\"; journalctl --user -u $unit --no-pager -o cat -n 3" ;;
|
||||
uninstall) "$frame" --host "systemctl --user disable --now $unit 2>/dev/null; rm -f ~/.config/systemd/user/$unit; systemctl --user daemon-reload; echo removed" ;;
|
||||
start|stop|restart) if installed; then "$frame" --host "systemctl --user $1 $unit; systemctl --user is-active $unit"; exit; fi ;;&
|
||||
log) if installed; then "$frame" --host "journalctl --user -u $unit --no-pager -o cat -n ${2:-30}"; exit; fi ;;&
|
||||
|
||||
Reference in new issue
Block a user