name: Package on: workflow_call: permissions: contents: read jobs: wheel: runs-on: ubuntu-latest steps: - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0 with: persist-credentials: false - uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0 with: go-version-file: strix/interface/tui/go.mod cache-dependency-path: strix/interface/tui/go.sum - uses: ./.github/actions/setup-python-env - run: uv build --wheel - name: Wheel ships the TUI sidecar and the viewer bundle run: | uv run --frozen python - <<'PY' import glob, zipfile (wheel,) = glob.glob("dist/*.whl") names = zipfile.ZipFile(wheel).namelist() assert "strix/bin/strix-tui" in names, names assert "strix/interface/viewer/static/index.html" in names, names assert not any(name.startswith("strix/interface/viewer/frontend/") for name in names) assert not any(name.startswith("strix/interface/tui/cmd/") for name in names) PY - name: Install into a clean environment and run the CLI run: | uv venv --python 3.12 /tmp/strix-smoke uv pip install --python /tmp/strix-smoke/bin/python dist/*.whl /tmp/strix-smoke/bin/strix --version /tmp/strix-smoke/bin/strix --help >/dev/null binary: runs-on: ubuntu-latest steps: - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0 with: persist-credentials: false - uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0 with: go-version-file: strix/interface/tui/go.mod cache-dependency-path: strix/interface/tui/go.sum - uses: ./.github/actions/setup-python-env - run: make tui-build - run: uv run --frozen pyinstaller strix.spec --noconfirm - run: dist/strix --version - name: Binary bundles the TUI sidecar run: uv run --frozen pyi-archive_viewer -l dist/strix | grep -E "strix/bin/strix-tui" >/dev/null