Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions .github/workflows/package-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -689,3 +689,46 @@ jobs:
ffmpeg -hide_banner -encoders \
> "$RUNNER_TEMP/ffmpeg-encoders.txt" 2>&1
grep -qw libx264 "$RUNNER_TEMP/ffmpeg-encoders.txt"

nix:
name: Nix flake
# Tagged releases build only the published package formats; a change in
# nixpkgs must not block them.
if: github.event_name != 'push' || !startsWith(github.ref, 'refs/tags/')
runs-on: ubuntu-24.04
timeout-minutes: 45
steps:
- name: Check out source
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false

- name: Install Nix
uses: cachix/install-nix-action@13d8dd58da0234aa297dedd986986ccb8e7f3e24 # v31.11.1
with:
extra_nix_config: |
experimental-features = nix-command flakes

- name: Build the flake and check its output
shell: bash
run: |
set -euo pipefail
nix build .#default --print-build-logs
version=$(tr -d '\r\n' < VERSION)
test "$(result/bin/tryx --version)" = "tryx $version"
test "$(result/bin/tryx-panorama-manager --version)" = \
"tryx-panorama-manager $version"
test -x result/lib/tryx-panorama-manager/tryx-panorama-runtime
test -f result/lib/udev/rules.d/70-tryx-pase-access.rules
test -f result/lib/udev/rules.d/99-tryx-pase-printer.rules
unit=result/share/systemd/user/tryx-panorama.service
grep -qx "ExecStart=$(readlink -f result)/lib/tryx-panorama-manager/tryx-panorama-runtime" "$unit"
grep -qx 'KillMode=mixed' "$unit"
# The runtime finds ffmpeg through PATH; its wrapper must provide
# one with the libx264 encoder that media preparation needs.
ffmpeg_bin=$(grep -a -o '/nix/store/[^:]*-ffmpeg-[^:]*/bin' \
result/lib/tryx-panorama-manager/tryx-panorama-runtime | sort -u)
test "$(printf '%s\n' "$ffmpeg_bin" | wc -l)" -eq 1
"$ffmpeg_bin/ffmpeg" -hide_banner -encoders \
> "$RUNNER_TEMP/ffmpeg-encoders.txt" 2>&1
grep -qw libx264 "$RUNNER_TEMP/ffmpeg-encoders.txt"
30 changes: 30 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -651,6 +651,36 @@ makepkg --cleanbuild --check
popd
```

## NixOS

The repository is a Nix flake, contributed by @Yuna404. It builds the same
files as the native packages: the GUI, the `tryx` client, the runtime with
ffmpeg on its `PATH`, the udev rules and the user service. CI builds it on
every change; NixOS itself is community-tested. The flake ships with releases
after 2.5.3. `github:DXVSI/Tryx-Linux-GUI` follows the latest release; add a
release tag to the URL to pin one.

Add the flake as an input:

```nix
tryx.url = "github:DXVSI/Tryx-Linux-GUI";
```

Then enable the package, its udev rules and the user service in the NixOS
configuration. Without the udev rules the application cannot open the display.

```nix
{ inputs, pkgs, ... }:
{
nixpkgs.overlays = [ inputs.tryx.overlays.default ];

environment.systemPackages = [ pkgs.tryx-panorama-manager ];
services.udev.packages = [ pkgs.tryx-panorama-manager ];
systemd.packages = [ pkgs.tryx-panorama-manager ];
systemd.user.services.tryx-panorama.wantedBy = [ "graphical-session.target" ];
}
```

## Requirements

**Build:**
Expand Down
8 changes: 4 additions & 4 deletions tests/quick/qml/tst_mainlifecycleguard.qml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ TestCase {
height: 760

ListModel {
id: mediaModel
id: mediaModelMock
ListElement {
mediaName: "one.mp4.h264_2240x1080"
mediaId: "media-one"
Expand All @@ -37,7 +37,7 @@ TestCase {
}

ListModel {
id: operationModel
id: operationModelMock
}

QtObject {
Expand Down Expand Up @@ -115,8 +115,8 @@ TestCase {
property var savedLayoutModel: []
property string metricsAlignment: "Left"
property string metricsColor: "#dcdcdc"
property var mediaModel: mediaModel
property var operationModel: operationModel
property var mediaModel: mediaModelMock
property var operationModel: operationModelMock
property int fullSubmitCount: 0
property int splitSubmitCount: 0
property string lastSubmissionId: ""
Expand Down
Loading