ci: ensure demos are built #130
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: dmd | ||
| on: | ||
| push: | ||
| branches: ["main"] | ||
| pull_request: | ||
| branches: ["main"] | ||
| permissions: | ||
| contents: read | ||
| jobs: | ||
| build: | ||
| strategy: | ||
| matrix: | ||
| os: [ubuntu-latest, windows-latest] | ||
| dc: [dmd-latest] | ||
| runs-on: ${{ matrix.os }} | ||
| steps: | ||
| - name: Checkout Source | ||
| uses: actions/checkout@v6 | ||
| - name: D Compiler Installation | ||
| uses: dlang-community/setup-dlang@v2 | ||
| with: | ||
| compiler: ${{ matrix.dc }} | ||
| - name: Build and Test | ||
| run: | | ||
| dub -q test | ||
| build-demo: | ||
| needs: build | ||
| strategy: | ||
| matrix: | ||
| os: [ubuntu-latest, windows-latest] | ||
| dc: [dmd-latest] | ||
| demos: [clipboard colors hello mouse styles] | ||
| runs-on: ${{ matrix.os }} | ||
| steps: | ||
| - name: Checkout Source | ||
| uses: actions/checkout@v6 | ||
| - name: D Compiler Installation | ||
| uses: dlang-community/setup-dlang@v2 | ||
| with: | ||
| compiler: ${{ matrix.dc }} | ||
| - name: Build demo | ||
| env: | ||
| demo: ${{ matrix.demos }} | ||
| run: | | ||
| cd demos/${{ demo }} | ||
| dub build | ||