desktop: the window installs itself (launcher entry, icon, default.nix)
app/linux/cst-agent-app.{desktop,svg} plus one CMake component ("app") in
app/CMakeLists.txt: `cmake --install --component app` puts the binary in bin/,
the entry in share/applications/ and the icon in hicolor/scalable/apps/. The
entry's file name stays the app_id Qt sets (QGuiApplication::applicationName),
or the launcher draws a generic icon; only the front end installs, the CLI
keeps coming from scripts/bootstrap_linux.sh.
default.nix is that install for nix users: nixpkgs' Qt 6 (qtwayland for a
Wayland session, qtsvg for Breeze's SVG icons), wrapQtAppsHook so the plugins
and QML modules resolve outside a nix-shell and survive nix-collect-garbage,
a filtered src (third_party/ and the build directories are gigabytes this
build never reads), and the version read from include/cst_version.h. doCheck
runs ctest minus test_sandbox, whose Landlock assertion cannot hold inside the
nix build sandbox (the other 40 pass there; make check runs all 41).
Verified: nix-build, nix profile add --file ., then --selftest and --uitest in
a clean environment (no nix-shell, no XDG_* from the session).
This commit is contained in:
@@ -45,6 +45,31 @@ navigation drawer) so swapping in `org.kde.kirigami` later is a QML-only
|
||||
change. Point the app at a Kirigami outside the Qt prefix with
|
||||
`-DCST_APP_QML_IMPORT=/path/to/qml`.
|
||||
|
||||
## Install (Linux desktop)
|
||||
|
||||
The window installs itself: the binary, a launcher entry and the icon the
|
||||
launcher draws for it. All three are one CMake component (`app`), so the CLI
|
||||
keeps coming from `scripts/bootstrap_linux.sh` and the profile never holds two
|
||||
`cst-agent` of different vintages; the files live in `app/linux/`.
|
||||
|
||||
```sh
|
||||
# NixOS / nix users: PATH + menu entry + icon. The Qt apps hook bakes the
|
||||
# plugin and QML module paths into the wrapper, so the app runs outside a
|
||||
# nix-shell and nix-collect-garbage cannot pull Qt out from under it.
|
||||
nix-build # ./result/bin/cst-agent-app, run it in place
|
||||
nix profile add --file . # or: ./result/bin/cst-agent-app
|
||||
nix profile remove cst-agent # uninstall
|
||||
|
||||
# anywhere with Qt 6 (Quick/Qml/QuickControls2) and libcurl:
|
||||
cmake -B build-app -DCST_BUILD_APP=ON -DCMAKE_BUILD_TYPE=Release
|
||||
cmake --build build-app -j
|
||||
cmake --install build-app --component app --prefix ~/.local
|
||||
```
|
||||
|
||||
Launched from a menu, the workspace is the directory the app starts in
|
||||
(`$HOME` there), so sessions land in `~/.agent/sessions`; pass
|
||||
`--workspace <dir>` to pin another one.
|
||||
|
||||
## Why in one process
|
||||
|
||||
The engine is a library, not a daemon: `libcstcore.a` (Makefile) / the
|
||||
@@ -408,6 +433,7 @@ so nothing about it is visible when the app is idle.
|
||||
file card's open/share through the app's FileProvider
|
||||
- [x] a turn keeps running with the app off screen (Android foreground service
|
||||
+ wake lock; nothing to do on a desktop)
|
||||
- [x] desktop install: launcher entry + icon, `nix profile add --file .`
|
||||
- [ ] a real turn driven through the window (needs a provider key)
|
||||
- [ ] SAF file picker, the back gesture, the icon glyphs on the phone
|
||||
- [ ] Kirigami (the rest of the Breeze look: colors, controls), tray,
|
||||
|
||||
Reference in New Issue
Block a user