Skip to content

Expose ddkbuild on PATH #20

Expose ddkbuild on PATH

Expose ddkbuild on PATH #20

Workflow file for this run

name: ci
on:
workflow_dispatch:
pull_request:
push:
branches:
- master
tags:
- "v*.*.*"
permissions:
contents: read
jobs:
test:
name: build and e2e
runs-on: windows-2025-vs2026
timeout-minutes: 90
steps:
- name: checkout
uses: actions/checkout@v4
- name: setup node
uses: actions/setup-node@v4
with:
node-version: 24
cache: npm
- name: install dependencies
shell: powershell
run: npm.cmd ci
- name: build bundle
shell: powershell
run: npm.cmd run build
- name: verify checked-in bundle
shell: powershell
run: git diff --exit-code -- dist/index.js
- name: setup wdk7
uses: ./
- name: run e2e
shell: powershell
run: .\scripts\test-e2e.ps1 -Mode default
- name: setup wdk7 with debugger
uses: ./
with:
debugger: true
- name: run debugger e2e
shell: powershell
run: .\scripts\test-e2e.ps1 -Mode debugger
release:
name: release
needs: test
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: create release
env:
GH_TOKEN: ${{ github.token }}
TAG_NAME: ${{ github.ref_name }}
run: |
if ! [[ "$TAG_NAME" =~ ^v([0-9]+)\.[0-9]+\.[0-9]+$ ]]; then
echo "Skipping release for non-semver tag: $TAG_NAME"
exit 0
fi
if gh release view "$TAG_NAME" >/dev/null 2>&1; then
echo "Release $TAG_NAME already exists."
else
gh release create "$TAG_NAME" --verify-tag --generate-notes --title "$TAG_NAME"
fi
- name: update major tag
env:
TAG_NAME: ${{ github.ref_name }}
run: |
if ! [[ "$TAG_NAME" =~ ^v([0-9]+)\.[0-9]+\.[0-9]+$ ]]; then
exit 0
fi
MAJOR_TAG="v${BASH_REMATCH[1]}"
TARGET_SHA="$(git rev-list -n 1 "$TAG_NAME")"
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git tag -f "$MAJOR_TAG" "$TARGET_SHA"
git push -f origin "refs/tags/$MAJOR_TAG"