VectorCraft: An open-source, vector art tool written by scratch in pure Rust
ci: retain VectorCraft package and release checks
skylartaylor2fa10c957cf8
diff --git a/.github/workflows/freebsd.yml b/.github/workflows/freebsd.ymlindex bdfdc21c1..f58f270b4 100644--- a/.github/workflows/freebsd.yml+++ b/.github/workflows/freebsd.yml@@ -7,6 +7,7 @@ on:paths:- ".github/workflows/freebsd.yml"- "packaging/freebsd/**"+ - "packaging/env.sh"- "Cargo.toml"- "Cargo.lock"- "crates/**"@@ -15,6 +16,7 @@ on:paths:- ".github/workflows/freebsd.yml"- "packaging/freebsd/**"+ - "packaging/env.sh"- "Cargo.toml"- "Cargo.lock"- "crates/**"@@ -32,4 +34,49 @@ jobs:# Intentionally tracked at @main (not SHA-pinned) so org-wide CI improvements, security fixes, and build optimizations propagate without PR churn across all craftapp repos.uses: storytold/craft-common-actions/.github/workflows/freebsd.yml@mainwith:+ require-craft-fonts: truecraft-fonts-ref: 3d9ab3a132ed0eff457e424226a435a901da30d3++ package:+ name: FreeBSD 14 (package)+ # The release build takes a while: only for PRs that touch FreeBSD packaging (or dependencies)+ # and on demand, not on every push to main.+ if: github.event_name != 'push'+ runs-on: ubuntu-latest+ timeout-minutes: 150+ steps:+ - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1+ # Japanese, Chinese, Arabic and Thai fonts, embedded by crates/text/build.rs (CRAFT_FONTS_DIR in the VM).+ # Bump the commit deliberately; see craftrules standards/fonts.md.+ - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1+ with:+ repository: storytold/craft-fonts+ ref: 3d9ab3a132ed0eff457e424226a435a901da30d3+ path: craft-fonts+ - name: Package in a FreeBSD VM+ uses: vmactions/freebsd-vm@c46abacb49f09938ca4e1702d15d836285d694cc # v1.5.9+ with:+ release: "14.3"+ usesh: true+ mem: 12288+ prepare: |+ pkg install -y bash curl git pkgconf cmake python3 libxkbcommon wayland libX11 libXcursor libXrandr libXi libxcb mesa-libs vulkan-loader gtk3 fontconfig freetype2 alsa-lib+ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal --default-toolchain stable+ run: |+ . "$HOME/.cargo/env"+ git config --global --add safe.directory "$PWD"+ # Build outside the checkout so only dist/ is copied back out of the VM.+ # The craft-fonts checkout is synced into the VM with the workspace.+ export CRAFT_FONTS_DIR="$PWD/craft-fonts" CRAFT_FONTS_REQUIRED=1+ export CARGO_TARGET_DIR=/var/tmp/vectorcraft-target CARGO_BUILD_JOBS=4+ bash packaging/freebsd/package.sh+ # Every part the package must have, the craft-fonts licences included.+ tar -tzf dist/release/vectorcraft-*-freebsd-x86_64.tar.gz >/var/tmp/contents.txt+ for want in '/bin/vectorcraft$' '/bin/vectorcraft-cli$' '/share/applications/.*\.desktop$' '/share/icons/hicolor/' '/share/doc/vectorcraft/NOTICE$' '/share/doc/vectorcraft/OFL-.*\.txt$'; do+ grep -Eq "$want" /var/tmp/contents.txt || { echo "missing from the package: $want"; exit 1; }+ done+ - uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2+ with:+ name: freebsd-package+ path: dist/release/*+ if-no-files-found: errordiff --git a/.github/workflows/packaging-lint.yml b/.github/workflows/packaging-lint.ymlindex f54b0538b..386989022 100644--- a/.github/workflows/packaging-lint.yml+++ b/.github/workflows/packaging-lint.yml@@ -21,3 +21,5 @@ jobs:lint:# Intentionally tracked at @main (not SHA-pinned) so org-wide CI improvements, security fixes, and build optimizations propagate without PR churn across all craftapp repos.uses: storytold/craft-common-actions/.github/workflows/packaging-lint.yml@main+ with:+ extra-checks-script: packaging/check-app-specific.shdiff --git a/.github/workflows/release.yml b/.github/workflows/release.ymlindex 777c97368..9161aee6e 100644--- a/.github/workflows/release.yml+++ b/.github/workflows/release.yml@@ -37,3 +37,9 @@ jobs:APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}WINDOWS_CERTIFICATE: ${{ secrets.WINDOWS_CERTIFICATE }}WINDOWS_CERTIFICATE_PASSWORD: ${{ secrets.WINDOWS_CERTIFICATE_PASSWORD }}+ AZURE_CERT_PROFILE: ${{ secrets.AZURE_CERT_PROFILE }}+ AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}+ AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}+ AZURE_SIGNING_ACCOUNT: ${{ secrets.AZURE_SIGNING_ACCOUNT }}+ AZURE_SIGNING_ENDPOINT: ${{ secrets.AZURE_SIGNING_ENDPOINT }}+ AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}diff --git a/packaging/check-app-specific.sh b/packaging/check-app-specific.shnew file mode 100755index 000000000..1d5d3b309--- /dev/null+++ b/packaging/check-app-specific.sh@@ -0,0 +1,17 @@+#!/usr/bin/env bash+# App-specific package assertions retained alongside shared packaging lint.+set -euo pipefail+cd "$(dirname "${BASH_SOURCE[0]}")/.."++python3 - <<'PYEOF'+import yaml+manifests = []+for name in ("ai.storyteller.vectorcraft.yml", "ai.storyteller.vectorcraft.bundle.yml"):+ with open("packaging/linux/flatpak/" + name) as source:+ manifest = yaml.safe_load(source)+ assert manifest["id"] == "ai.storyteller.vectorcraft" and manifest["command"] == "vectorcraft", name+ manifests.append(manifest)+for key in ("runtime", "runtime-version", "sdk", "finish-args"):+ assert manifests[0][key] == manifests[1][key], f"Flatpak manifests disagree on {key}"+print("VectorCraft package identity ok")+PYEOF