name: Compiler Explorer on Windows

on: [push, pull_request]

jobs:
  test:
    runs-on: windows-2019

    steps:
      - name: Ask Git to use LF line endings
        run: |
          git config --global core.autocrlf false
          git config --global core.eol lf
      - uses: actions/checkout@v3
        with:
          fetch-depth: 0
      - name: Use Node.js 18.x
        uses: actions/setup-node@v3
        with:
          node-version: 18.x
          cache: npm
      - name: Install prerequisites
        run: make prereqs
      - name: Build and test
        run: |
          npm run lint-check
          npm run ci-test
          npm run ts-check
