ci.yml 19.8 KB
Newer Older
E
Edward Thomson 已提交
1 2
name: CI

J
João Moreno 已提交
3 4
on:
  push:
5 6 7 8 9 10 11
    branches:
      - master
      - release/*
  pull_request:
    branches:
      - master
      - release/*
E
Edward Thomson 已提交
12 13

jobs:
14
  hygiene:
A
Alexandru Dima 已提交
15
    name: Hygiene and Layering
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
    runs-on: ubuntu-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Cache node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
40 41 42
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
43 44 45 46 47
        run: yarn --frozen-lockfile

      - name: Run Hygiene Checks
        run: yarn gulp hygiene

48 49 50
      - name: Run Valid Layers Checks
        run: yarn valid-layers-check

A
Alexandru Dima 已提交
51 52
  build-compile:
    name: "Build: Compile"
A
Alexandru Dima 已提交
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92
    runs-on: ubuntu-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Cache node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
        run: yarn --frozen-lockfile

      - name: Cache compiled code
        id: cacheCompiledCode
        uses: actions/cache@v2
        with:
          path: |
            .build
            out-build
            out-vscode-min
          key: cacheCompiledCode-${{ env.GITHUB_SHA }}

      - name: Compile Core
93
        if: ${{ steps.cacheCompiledCode.outputs.cache-hit != 'true' }}
A
Alexandru Dima 已提交
94 95 96
        run: yarn gulp compile-build

      - name: Compile Extensions
97
        if: ${{ steps.cacheCompiledCode.outputs.cache-hit != 'true' }}
A
Alexandru Dima 已提交
98 99 100
        run: yarn gulp compile-extensions-build

      - name: Minify VS Code
101
        if: ${{ steps.cacheCompiledCode.outputs.cache-hit != 'true' }}
A
Alexandru Dima 已提交
102 103
        run: yarn gulp minify-vscode

A
Alexandru Dima 已提交
104 105 106
  build-linux-unit-tests:
    name: "Build: Linux Unit Tests"
    needs: build-compile
A
Alexandru Dima 已提交
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166
    runs-on: ubuntu-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      # TODO: rename azure-pipelines/linux/xvfb.init to github-actions
      - name: Setup Build Environment
        run: |
          sudo apt-get update
          sudo apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 libgbm1
          sudo cp build/azure-pipelines/linux/xvfb.init /etc/init.d/xvfb
          sudo chmod +x /etc/init.d/xvfb
          sudo update-rc.d xvfb defaults
          sudo service xvfb start

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Restore cached node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-

      - name: Restore cached /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}

      - name: Restore cached compiled code
        id: cacheCompiledCode
        uses: actions/cache@v2
        with:
          path: |
            .build
            out-build
            out-vscode-min
          key: cacheCompiledCode-${{ env.GITHUB_SHA }}

      - name: Build VS Code
        run: yarn gulp vscode-linux-x64-min-ci

      - name: Download Electron
        run: yarn electron x64

      - name: Run Unit Tests (Electron)
        run: DISPLAY=:10 ./scripts/test.sh --build

      - name: Download Playwright
        run: node ./node_modules/playwright/install.js

      - name: Run Unit Tests (Browser)
        run: DISPLAY=:10 yarn test-browser --build --browser chromium

A
Alexandru Dima 已提交
167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220
  build-linux-integration-tests:
    name: "Build: Linux Integration Tests"
    needs: build-compile
    runs-on: ubuntu-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      # TODO: rename azure-pipelines/linux/xvfb.init to github-actions
      - name: Setup Build Environment
        run: |
          sudo apt-get update
          sudo apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 libgbm1
          sudo cp build/azure-pipelines/linux/xvfb.init /etc/init.d/xvfb
          sudo chmod +x /etc/init.d/xvfb
          sudo update-rc.d xvfb defaults
          sudo service xvfb start

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Restore cached node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-

      - name: Restore cached /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}

      - name: Restore cached compiled code
        id: cacheCompiledCode
        uses: actions/cache@v2
        with:
          path: |
            .build
            out-build
            out-vscode-min
          key: cacheCompiledCode-${{ env.GITHUB_SHA }}

      - name: Build VS Code
        run: yarn gulp vscode-linux-x64-min-ci

      - name: Download Electron
        run: yarn electron x64

A
Alexandru Dima 已提交
221 222
      - name: Run Integration Tests (Electron)
        run: DISPLAY=:10 ./scripts/test-integration.sh --build
223

A
Alexandru Dima 已提交
224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384
  build-darwin-unit-tests:
    name: "Build: macOS Unit Tests"
    needs: build-compile
    runs-on: macos-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Cache node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
        run: yarn --frozen-lockfile

      - name: Restore cached compiled code
        id: cacheCompiledCode
        uses: actions/cache@v2
        with:
          path: |
            .build
            out-build
            out-vscode-min
          key: cacheCompiledCode-${{ env.GITHUB_SHA }}

      - name: Build VS Code
        run: yarn gulp vscode-darwin-x64-min-ci

      - name: Download Electron
        run: yarn electron x64

      - name: Run Unit Tests (Electron)
        run: ./scripts/test.sh --build

      - name: Download Playwright
        run: node ./node_modules/playwright/install.js

      - name: Run Unit Tests (Browser)
        run: yarn test-browser --build --browser chromium --browser webkit --browser firefox

  build-darwin-integration-tests:
    name: "Build: macOS Integration Tests"
    needs: build-compile
    runs-on: macos-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Cache node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
        run: yarn --frozen-lockfile

      - name: Restore cached compiled code
        id: cacheCompiledCode
        uses: actions/cache@v2
        with:
          path: |
            .build
            out-build
            out-vscode-min
          key: cacheCompiledCode-${{ env.GITHUB_SHA }}

      - name: Build VS Code
        run: yarn gulp vscode-darwin-x64-min-ci

      - name: Download Electron
        run: yarn electron x64

      - name: Run Integration Tests (Electron)
        run: ./scripts/test-integration.sh --build

  build-darwin-smoke-tests:
    name: "Build: macOS Smoke Tests"
    needs: build-compile
    runs-on: macos-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Cache node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
        run: yarn --frozen-lockfile

      - name: Restore cached compiled code
        id: cacheCompiledCode
        uses: actions/cache@v2
        with:
          path: |
            .build
            out-build
            out-vscode-min
          key: cacheCompiledCode-${{ env.GITHUB_SHA }}

      - name: Build VS Code
        run: yarn gulp vscode-darwin-x64-min-ci

      - name: Run Smoke Tests (Electron)
        continue-on-error: true
        run: |
          set -e
          APP_ROOT=$(GITHUB_WORKSPACE)/VSCode-darwin-x64
          APP_NAME="`ls $APP_ROOT | head -n 1`"
          yarn smoketest --build "$APP_ROOT/$APP_NAME"

385
  linux:
386
    name: Linux
387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407
    runs-on: ubuntu-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      # TODO: rename azure-pipelines/linux/xvfb.init to github-actions
      - name: Setup Build Environment
        run: |
          sudo apt-get update
          sudo apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 libgbm1
          sudo cp build/azure-pipelines/linux/xvfb.init /etc/init.d/xvfb
          sudo chmod +x /etc/init.d/xvfb
          sudo update-rc.d xvfb defaults
          sudo service xvfb start

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Cache node modules
A
Alexandru Dima 已提交
408
        id: cacheNodeModules
409 410
        uses: actions/cache@v2
        with:
A
Alexandru Dima 已提交
411 412 413 414 415
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
416 417 418
        uses: actions/cache@v2
        with:
          path: build/**/*.js
A
Alexandru Dima 已提交
419 420
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
A
Alexandru Dima 已提交
421
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
422 423
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
A
Alexandru Dima 已提交
424
        run: yarn --frozen-lockfile
425

A
Alexandru Dima 已提交
426
      - name: Compile and Download
A
Alexandru Dima 已提交
427
        run: yarn concurrently --max_old_space_size=4095 --names "compile,electron,playwright,builtin-extensions" "node --max_old_space_size=4095 ./node_modules/gulp/bin/gulp.js compile" "yarn electron x64" "node ./node_modules/playwright/install.js" "yarn download-builtin-extensions"
428

A
Alexandru Dima 已提交
429 430
      - name: Run Unit Tests (Electron)
        run: DISPLAY=:10 ./scripts/test.sh
431

A
Alexandru Dima 已提交
432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484
      - name: Run Unit Tests (Browser)
        run: DISPLAY=:10 yarn test-browser --browser chromium

      - name: Run Integration Tests (Electron)
        run: DISPLAY=:10 ./scripts/test-integration.sh

  windows:
    name: Windows
    runs-on: windows-latest
    env:
      CHILD_CONCURRENCY: "1"
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - uses: actions/setup-python@v2
        with:
          python-version: '2.x'

      - name: Cache node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
        run: yarn --frozen-lockfile

      - name: Compile and Download
        run: yarn concurrently --max_old_space_size=4095 --names "compile,electron,playwright,builtin-extensions" "node --max_old_space_size=4095 ./node_modules/gulp/bin/gulp.js compile" "yarn electron x64" "node ./node_modules/playwright/install.js" "yarn download-builtin-extensions"

      - name: Run Unit Tests (Electron)
        run: .\scripts\test.bat

      - name: Run Unit Tests (Browser)
        run: yarn test-browser --browser chromium

      - name: Run Integration Tests (Electron)
        run: .\scripts\test-integration.bat
E
Edward Thomson 已提交
485

A
Alexandru Dima 已提交
486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519
  darwin:
    name: macOS
    runs-on: macos-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
      - uses: actions/checkout@v2

      - uses: actions/setup-node@v2-beta
        with:
          node-version: 12

      - name: Cache node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
        run: yarn --frozen-lockfile

      - name: Compile and Download
        run: yarn concurrently --max_old_space_size=4095 --names "compile,electron,playwright,builtin-extensions" "yarn compile" "yarn electron x64" "node ./node_modules/playwright/install.js" "yarn download-builtin-extensions"

A
Alexandru Dima 已提交
520 521 522 523 524 525 526 527
      - name: Run Unit Tests (Electron)
        run: DISPLAY=:10 ./scripts/test.sh

      - name: Run Unit Tests (Browser)
        run: DISPLAY=:10 yarn test-browser --browser chromium

      - name: Run Integration Tests (Electron)
        run: DISPLAY=:10 ./scripts/test-integration.sh
528 529

  monaco:
A
Alexandru Dima 已提交
530
    name: Monaco Editor
531
    runs-on: ubuntu-latest
532 533 534
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
    steps:
A
Alex Dima 已提交
535
      - uses: actions/checkout@v2
536

A
Alex Dima 已提交
537
      - uses: actions/setup-node@v2-beta
J
João Moreno 已提交
538
        with:
A
Alex Dima 已提交
539
          node-version: 12
540

541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558
      - name: Cache node modules
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: '**/node_modules'
          key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('.yarnrc', 'remote/.yarnrc', '**/yarn.lock', '!**/node_modules/**/yarn.lock', '!**/.*/**/yarn.lock') }}
          restore-keys: ${{ runner.os }}-cacheNodeModules-
      - name: Cache /build/ scripts
        id: cacheBuildScripts
        uses: actions/cache@v2
        with:
          path: build/**/*.js
          key: ${{ runner.os }}-cacheBuildScripts-${{ hashFiles('build/yarn.lock', 'build/tsconfig.json', 'build/tsconfig.build.json', 'build/**/*.ts', '!**/node_modules/**/*.ts') }}
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' || steps.cacheBuildScripts.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
        run: yarn --frozen-lockfile
559

560 561 562 563 564
      - name: Run Monaco Editor Checks
        run: yarn monaco-compile-check

      - name: Editor Distro & ESM Bundle
        run: yarn gulp editor-esm-bundle