From 7a9cff59a734473e4ef91401f356343cf0077d3a Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Mon, 22 Nov 2021 21:57:39 +0100 Subject: [PATCH] First attempt at nightly --- .github/workflows/ci.yml | 4 +- .github/workflows/nightly.yml | 100 ++++++++++++++++++++++++++++++++++ .github/workflows/website.yml | 2 +- 3 files changed, 103 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/nightly.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3d62fa9b..00e35d28 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,11 +23,11 @@ jobs: - name: Install node modules (1) if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }} - run: npm install + run: npm ci - name: Install node modules (2) if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }} - run: npm install --prefix webpack-plugin + run: npm ci --prefix webpack-plugin - name: Install Playwright run: npm run playwright-install diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml new file mode 100644 index 00000000..2d7b6041 --- /dev/null +++ b/.github/workflows/nightly.yml @@ -0,0 +1,100 @@ +name: Publish Nightly + +on: + push: + branches: + - main + +jobs: + nightly: + name: Publish Nightly + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - uses: actions/setup-node@v2 + with: + node-version: 14 + + - name: Cache node modules + id: cacheNodeModules + uses: actions/cache@v2 + with: + path: '**/node_modules' + key: ${{ runner.os }}-cacheNodeModules-${{ hashFiles('**/package-lock.json') }} + restore-keys: ${{ runner.os }}-cacheNodeModules- + + - name: Install node modules (1) + if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }} + run: npm ci + + - name: \[vscode\] checkout + uses: actions/checkout@v2 + with: + repository: 'microsoft/vscode' + path: '../vscode' + + - name: \[vscode\] execute `yarn` + working-directory: '../vscode' + run: yarn --frozen-lockfile --network-timeout 180000 + + - name: \[vscode\] Run Hygiene Checks + working-directory: '../vscode' + run: yarn gulp hygiene + + - name: \[vscode\] Run Valid Layers Checks + working-directory: '../vscode' + run: yarn valid-layers-check + + - name: \[vscode\] Compile /build/ + working-directory: '../vscode' + run: yarn --cwd build compile + + - name: \[vscode\] Run eslint + working-directory: '../vscode' + run: yarn eslint + + - name: \[vscode\] Run Monaco Editor Checks + working-directory: '../vscode' + run: yarn monaco-compile-check + + - name: \[vscode\] Compile + working-directory: '../vscode' + run: yarn --max_old_space_size=4095 compile + + - name: \[vscode\] Run Unit Tests (Browser) + working-directory: '../vscode' + run: DISPLAY=:10 yarn test-browser --browser chromium + + - name: \[vscode\] Editor Distro & ESM Bundle + working-directory: '../vscode' + run: yarn gulp editor-esm-bundle + + - name: \[vscode\] Typings validation prep + working-directory: '../vscode' + run: mkdir typings-test + + - name: \[vscode\] Typings validation + working-directory: ../vscode/typings-test + run: | + yarn init -yp + ../node_modules/.bin/tsc --init + echo "import '../out-monaco-editor-core';" > a.ts + ../node_modules/.bin/tsc --noEmit + + - name: \[vscode\] Webpack Editor + working-directory: ../vscode/test/monaco + run: yarn run bundle + + - name: \[vscode\] Compile Editor Tests + working-directory: ../vscode/test/monaco + run: yarn run compile + + - name: \[vscode\] Download Playwright + working-directory: ../vscode + run: yarn playwright-install + + - name: \[vscode\] Run Editor Tests + timeout-minutes: 5 + working-directory: ../vscode/test/monaco + run: yarn test diff --git a/.github/workflows/website.yml b/.github/workflows/website.yml index 7ca9678f..6719de3d 100644 --- a/.github/workflows/website.yml +++ b/.github/workflows/website.yml @@ -26,7 +26,7 @@ jobs: - name: Install node modules (1) if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }} - run: npm install + run: npm ci - name: Build website run: npm run build-website