# Quick static checks for the release pipeline (seconds, no Rust build): workflow syntax, # packaging shell/PowerShell scripts, and the Linux desktop/AppStream/Flatpak metadata. name: Packaging lint on: push: branches: [main, release] paths: [".github/workflows/**", "packaging/**", "assets/app-icon/**", "brand.toml"] pull_request: paths: [".github/workflows/**", "packaging/**", "assets/app-icon/**", "brand.toml"] workflow_dispatch: permissions: contents: read concurrency: group: packaging-lint-${{ github.ref }} cancel-in-progress: true jobs: lint: runs-on: ubuntu-latest env: ACTIONLINT_VERSION: 1.7.12 steps: - uses: actions/checkout@v4 - name: Install tools run: | sudo apt-get update sudo apt-get install -y --no-install-recommends shellcheck desktop-file-utils appstream libxml2-utils python3-yaml curl -fsSL "https://github.com/rhysd/actionlint/releases/download/v${ACTIONLINT_VERSION}/actionlint_${ACTIONLINT_VERSION}_linux_amd64.tar.gz" \ | tar -xz -C "$RUNNER_TEMP" actionlint - name: actionlint run: | "$RUNNER_TEMP/actionlint" -color - name: shellcheck run: shellcheck packaging/*.sh packaging/*/*.sh - name: PowerShell shell: pwsh run: | foreach ($f in Get-ChildItem packaging/windows/*.ps1) { $errors = $null [System.Management.Automation.Language.Parser]::ParseFile($f.FullName, [ref]$null, [ref]$errors) | Out-Null if ($errors) { $errors | ForEach-Object { Write-Output "::error file=$($f.Name)::$_" }; exit 1 } Write-Output "ok $($f.Name)" } - name: Render the packaging templates (brand.toml) run: | . packaging/env.sh OUT="$RUNNER_TEMP/pkg" for t in packaging/linux/*.in packaging/linux/flatpak/*.in packaging/macos/*.in packaging/windows/*.in; do rel="${t#packaging/}"; rel="${rel%.in}"; rel="${rel//\{app_id\}/$BRAND_APP_ID}" brand_render "$t" "$OUT/$rel" done echo "OUT=$OUT" >>"$GITHUB_ENV" echo "APP_ID=$BRAND_APP_ID" >>"$GITHUB_ENV" echo "APP_BINARY=$BRAND_BINARY" >>"$GITHUB_ENV" - name: XML, desktop entry, AppStream, Flatpak manifest run: | xmllint --noout "$OUT"/windows/app.wxs "$OUT"/macos/*.plist "$OUT"/linux/*.xml packaging/macos/entitlements.plist # Windows Installer needs Icon ids ending in .ico or .exe, or shortcuts show a blank icon. if grep -oE '