Skip to content
ALWasp
Menu

Workflow library

Copy the pattern.
Adapt the details.

Production-shaped examples for the moments that matter: first configuration, CI automation, authenticated restores, releases, and compatibility gates.

Eight practical recipes

From repository setup to release confidence.

Each example stays close to the current CLI and schema, so you can copy it first and refine it for your repository second.

Foundation

Config-driven CI target

Share analyzer defaults, inventory apps and tests, enforce AppSource warnings, and version only changed projects.

alwasp.json
{
  "$schema": "https://alwasp.dev/schema/alwasp.schema.json",
  "version": 1,
  "defaultTarget": "ci",
  "defaults": {
    "nowarn": ["AA0207"],
    "analyzers": { "codeCop": true }
  },
  "restore": {
    "enabled": true,
    "mode": "Locked",
    "packagesFolder": ".alpackages",
    "country": "W1"
  },
  "workspace": {
    "logDirectory": ".alwasp/logs",
    "manifest": ".alwasp/build-manifest.json",
    "maxCpuCount": 4,
    "continueOnError": false
  },
  "versioning": {
    "enabled": true,
    "releaseType": "Release",
    "source": "appJson",
    "applyTo": "changedOnly",
    "includeDependencies": true,
    "dependencyUpdateScope": "directlyChanged"
  },
  "changeDetection": {
    "mode": "git",
    "base": "latest-merge:version-increase",
    "includeDependents": true
  },
  "apps": [
    { "id": "Broker", "path": "./Broker" }
  ],
  "tests": [
    { "id": "BrokerTest", "path": "./BrokerTest", "app": "Broker" }
  ],
  "profiles": {
    "appsource": {
      "include": "apps",
      "outFolder": "output/appsource",
      "appSourceCop": true,
      "warningPolicy": { "treatWarningsAsErrors": true }
    },
    "test": {
      "include": "tests",
      "outFolder": "output/tests",
      "needsProfile": "appsource"
    }
  },
  "targets": {
    "ci": ["appsource", "test"]
  }
}

Automation

GitHub Actions build

Install ALWasp, validate configuration, build the CI target, and publish the manifest as a pipeline artifact.

.github/workflows/alwasp.yml
name: ALWasp

on:
  pull_request:
  push:
    branches: [main]

jobs:
  build:
    runs-on: windows-latest
    steps:
      - uses: actions/checkout@v4
        with:
          fetch-depth: 0

      - uses: actions/setup-dotnet@v4
        with:
          dotnet-version: 8.0.x

      - run: dotnet tool install --global left-code.AlWasp
      - run: alwasp config validate
      - run: alwasp tools update --check
        continue-on-error: true
      - run: alwasp build ci --auth-mode noninteractive --manifest output/build-manifest.json
        env:
          ALWASP_PAT: ${{ secrets.AZURE_ARTIFACTS_PAT }}

      - uses: actions/upload-artifact@v4
        with:
          name: build-manifest
          path: output/build-manifest.json

Authentication

Private feed restore

Map a feed to its own environment variable when multiple authenticated sources require separate credentials.

restore.sh
export MY_FEED_PAT="$TOKEN"
alwasp restore \
  --feed https://pkgs.dev.azure.com/org/_packaging/feed/nuget/v3/index.json \
  --feed-token-env https://pkgs.dev.azure.com/org/_packaging/feed/nuget/v3/index.json=MY_FEED_PAT \
  --auth-mode noninteractive

Dependency override

Use a pre-built dependency

Replace a restored package with another pipeline's artifact by embedded AppId during a config-driven build.

alwasp.json
{
  "restore": {
    "packagesFolder": ".alpackages",
    "overridesFolder": "artifacts/package-overrides"
  }
}

Release preparation

Apply versions permanently

Calculate project and internal dependency versions before the surrounding pipeline commits and tags them.

release.sh
alwasp version apply release --changed-since "latest-merge:version-increase"
git diff -- */app.json
git commit -am "Apply AL app versions"
git tag v2026.6.0

Sandbox workflow

Re-upload a compiled artifact

Assign a fresh deployment package ID without changing app identity or the rest of the ZIP payload.

reupload.ps1
alwasp app set-package-id ./output/developer/MyApp.app
alwasp app set-package-id ./output/developer/MyApp.app \
  --out ./output/reupload/MyApp.app

Quality gate

Multi-app compatibility

Recompile current source against previous packages, then read the informational public-symbol change log.

compatibility.sh
alwasp validate compatibility \
  --project-root ./src \
  --baseline-directory ./latest \
  --packages ./.alpackages \
  --ruleset ./rulesets/AppSourceCop.ruleset.json

alwasp compare \
  ./latest/MyApp.app \
  ./output/MyApp.app \
  --json ./output/compare.json

Quality gate

Translation coverage gate

Check only changed projects' XLIFF coverage before a release, with a per-language minimum and build annotations.

translations.sh
alwasp validate translations ci \
  --changed-since latest \
  --fail-on needs-review \
  --min-coverage 95 \
  --json output/translations.json

Need the field guide?

Keep every command within reach.