ci.yml 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. name: CI
  2. on:
  3. push:
  4. branches: [main, master]
  5. pull_request:
  6. concurrency:
  7. group: ${{ github.workflow }}-${{ github.ref }}
  8. cancel-in-progress: true
  9. permissions:
  10. contents: read
  11. env:
  12. PRIMARY_NODE_VERSION: '24'
  13. jobs:
  14. node-24:
  15. runs-on: ubuntu-latest
  16. name: node 24 / ${{ matrix.lane }}
  17. env:
  18. DSH_GATE_CONCURRENCY: ${{ matrix.gate_concurrency }}
  19. DSH_PUBLINT_CONCURRENCY: ${{ matrix.publint_concurrency }}
  20. DSH_COVERAGE_MAX_WORKERS: ${{ matrix.coverage_max_workers }}
  21. strategy:
  22. fail-fast: false
  23. matrix:
  24. include:
  25. - lane: static
  26. command: pnpm run check:ci:static
  27. gate_concurrency: '4'
  28. publint_concurrency: '8'
  29. coverage_max_workers: ''
  30. - lane: lint
  31. command: pnpm run check:ci:lint
  32. gate_concurrency: '1'
  33. publint_concurrency: '8'
  34. coverage_max_workers: ''
  35. - lane: coverage
  36. command: pnpm run check:ci:coverage
  37. gate_concurrency: '1'
  38. publint_concurrency: '8'
  39. coverage_max_workers: '4'
  40. - lane: snapshot
  41. command: pnpm run check:ci:snapshot
  42. gate_concurrency: '1'
  43. publint_concurrency: '8'
  44. coverage_max_workers: ''
  45. - lane: artifacts
  46. command: pnpm run check:ci:artifacts
  47. gate_concurrency: '3'
  48. publint_concurrency: '8'
  49. coverage_max_workers: ''
  50. steps:
  51. - uses: actions/checkout@v6
  52. - uses: actions/setup-node@v6
  53. with:
  54. node-version: ${{ env.PRIMARY_NODE_VERSION }}
  55. - name: Enable corepack (pnpm)
  56. run: corepack enable
  57. - name: Resolve pnpm store path
  58. id: pnpm-store
  59. run: echo "path=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT"
  60. - uses: actions/cache@v4
  61. with:
  62. path: ${{ steps.pnpm-store.outputs.path }}
  63. key: ${{ runner.os }}-node-${{ env.PRIMARY_NODE_VERSION }}-pnpm-${{ hashFiles('pnpm-lock.yaml') }}
  64. restore-keys: |
  65. ${{ runner.os }}-node-${{ env.PRIMARY_NODE_VERSION }}-pnpm-
  66. - name: Install (immutable)
  67. run: pnpm install --frozen-lockfile
  68. - name: Run gates
  69. run: ${{ matrix.command }}
  70. node-compat:
  71. runs-on: ubuntu-latest
  72. name: node 26
  73. env:
  74. DSH_GATE_CONCURRENCY: '2'
  75. strategy:
  76. fail-fast: false
  77. matrix:
  78. node: [26]
  79. steps:
  80. - uses: actions/checkout@v6
  81. - uses: actions/setup-node@v6
  82. with:
  83. node-version: ${{ matrix.node }}
  84. - name: Enable corepack (pnpm)
  85. run: corepack enable
  86. - name: Resolve pnpm store path
  87. id: pnpm-store
  88. run: echo "path=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT"
  89. - uses: actions/cache@v4
  90. with:
  91. path: ${{ steps.pnpm-store.outputs.path }}
  92. key: ${{ runner.os }}-node-${{ matrix.node }}-pnpm-${{ hashFiles('pnpm-lock.yaml') }}
  93. restore-keys: |
  94. ${{ runner.os }}-node-${{ matrix.node }}-pnpm-
  95. - name: Install (immutable)
  96. run: pnpm install --frozen-lockfile
  97. - name: Run compatibility gates
  98. run: pnpm run check:node-compat