- Wrapper now cds to $HOME, forwards args via "--" to avoid gjs parsing, expands GI_TYPELIB_PATH (incl. /usr/lib64/ags:/usr/lib/ags), and sets LD_LIBRARY_PATH for /usr/local libs.
- Ensure ESM entry com.github.Aylur.ags is 0644 under /usr/local/share and /usr/share.
Aligns Arch installer with Fedora fix; resolves "unknown option" and read-permission issues for `ags -t overview`.
Problem
- AGS v1 under GJS ESM ignores GIR Repository.prepend_*; typelibs in /usr/local aren’t discovered reliably.
- On Arch, users may install AGS into /usr/local while system typelibs can also live under /usr/lib64/ags or /usr/lib/ags.
Solution
- Keep the tolerant ESM patcher (no-op safe): remove deprecated GIR repo calls; ensure GLib import; inject GI_TYPELIB_PATH via GLib.setenv when editing the ESM main.
- Add a distro-agnostic wrapper at /usr/local/bin/ags that sets:
- GI_TYPELIB_PATH=/usr/local/lib64/girepository-1.0:/usr/local/lib/girepository-1.0:/usr/lib64/girepository-1.0:/usr/lib/girepository-1.0:/usr/local/lib64:/usr/local/lib:/usr/lib64/ags:/usr/lib/ags:$GI_TYPELIB_PATH
- LD_LIBRARY_PATH=/usr/local/lib64:/usr/local/lib:$LD_LIBRARY_PATH
Then execs: /usr/bin/gjs -m "$MAIN_JS" (resolved under /usr/local/share or /usr/share).
Why
- Ensures AGS v1 runs reliably on Arch without depending solely on fragile in-place edits; mirrors the working Fedora fix.
File
- install-scripts/ags.sh
Context:
- On systems where AGS v1 installs its typelibs to /usr/local/lib, gjs ESM imports like gi://GIRepository?version=2.0 fail with:
"Typelib file for namespace 'GIRepository', version '2.0' not found"
even though typelibs exist under /usr/lib{,64}/girepository-1.0.
- The upstream AGS launcher tries to call GIR.Repository.prepend_search_path()/prepend_library_path(),
but in recent GI (1.86) these are not available from the ESM namespace.
Changes:
- Replace import GIR from "gi://GIRepository?version=2.0" with import GLib from "gi://GLib" in the installed launcher.
- Remove deprecated GIR.Repository.prepend_search_path and prepend_library_path calls.
- Immediately after the GLib import, export GI_TYPELIB_PATH in-process so gjs finds typelibs under /usr/local/lib:
const __old = GLib.getenv('GI_TYPELIB_PATH');
GLib.setenv('GI_TYPELIB_PATH', '/usr/local/lib' + (__old ? ':' + __old : ''), true);
Result:
- ags -t overview no longer errors on GIRepository; proceeds until a GTK display is required.
- Behavior is scoped to the AGS process; no user shell env changes required.
Notes:
- Verified by patching an installed launcher on a target host; GI errors resolved.
Might need as backup when QS has issues.
The Hyprland DOTS now use a wrapper script to determine
which to use for overview
On branch development
Your branch is up to date with 'origin/development'.
Changes to be committed:
modified: quickshell.sh