<commit_before>name: CI

on:
  push:
    branches:
      - main
      - release/*
  pull_request:
    branches:
      - main
      - release/*

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

      - uses: actions/setup-node@v2
        with:
          node-version: 14

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

      - name: Compute node modules cache key
        id: nodeModulesCacheKey
        run: echo "::set-output name=value::$(node build/azure-pipelines/common/computeNodeModulesCacheKey.js)"
      - name: Cache node_modules archive
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: ".build/node_modules_cache"
          key: "${{ runner.os }}-cacheNodeModulesArchive-${{ steps.nodeModulesCacheKey.outputs.value }}"
      - name: Extract node_modules archive
        if: ${{ steps.cacheNodeModules.outputs.cache-hit == 'true' }}
        run: 7z.exe x .build/node_modules_cache/cache.7z -aos
      - name: Get yarn cache directory path
        id: yarnCacheDirPath
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
        run: echo "::set-output name=dir::$(yarn cache dir)"
      - name: Cache yarn directory
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
        uses: actions/cache@v2
        with:
          path: ${{ steps.yarnCacheDirPath.outputs.dir }}
          key: ${{ runner.os }}-yarnCacheDir-${{ steps.nodeModulesCacheKey.outputs.value }}
          restore-keys: ${{ runner.os }}-yarnCacheDir-
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
          ELECTRON_SKIP_BINARY_DOWNLOAD: 1
        run: |
          # update node-gyp to latest for support in detecting VS 2022 toolchain
          npm install -g node-gyp@latest
          # Resolve to node-gyp.js
          # Remove this once node-version > 17.4.x or > 16.14.0,
          # which ships with npm > 8.4.0 that has support for VS 2022 toolchain.
          $env:npm_config_node_gyp=$(Join-Path $(Get-Command node-gyp.cmd).Path "..\node_modules\node-gyp\bin\node-gyp.js" -Resolve)
          # Electron <= 13 does not ship with correct config.gypi headers,
          # remove this once we update to newer versions.
          # Refs https://github.com/nodejs/node-gyp/pull/2497
          $env:npm_config_force_process_config=true
          yarn --frozen-lockfile --network-timeout 180000
      - name: Create node_modules archive
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
        run: |
          mkdir -Force .build
          node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
          mkdir -Force .build/node_modules_cache
          7z.exe a .build/node_modules_cache/cache.7z -mx3 `@.build/node_modules_list.txt

      - name: Compile and Download
        run: yarn npm-run-all --max_old_space_size=4095 -lp compile "electron x64" playwright-install download-builtin-extensions

      - name: Compile Integration Tests
        run: yarn --cwd test/integration/browser compile

      - name: Run Unit Tests (Electron)
        run: .\scripts\test.bat<commit_msg>ci: fix env configuration (#144229)<commit_after>name: CI

on:
  push:
    branches:
      - main
      - release/*
  pull_request:
    branches:
      - main
      - release/*

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

      - uses: actions/setup-node@v2
        with:
          node-version: 14

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

      - name: Compute node modules cache key
        id: nodeModulesCacheKey
        run: echo "::set-output name=value::$(node build/azure-pipelines/common/computeNodeModulesCacheKey.js)"
      - name: Cache node_modules archive
        id: cacheNodeModules
        uses: actions/cache@v2
        with:
          path: ".build/node_modules_cache"
          key: "${{ runner.os }}-cacheNodeModulesArchive-${{ steps.nodeModulesCacheKey.outputs.value }}"
      - name: Extract node_modules archive
        if: ${{ steps.cacheNodeModules.outputs.cache-hit == 'true' }}
        run: 7z.exe x .build/node_modules_cache/cache.7z -aos
      - name: Get yarn cache directory path
        id: yarnCacheDirPath
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
        run: echo "::set-output name=dir::$(yarn cache dir)"
      - name: Cache yarn directory
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
        uses: actions/cache@v2
        with:
          path: ${{ steps.yarnCacheDirPath.outputs.dir }}
          key: ${{ runner.os }}-yarnCacheDir-${{ steps.nodeModulesCacheKey.outputs.value }}
          restore-keys: ${{ runner.os }}-yarnCacheDir-
      - name: Execute yarn
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
        env:
          PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
          ELECTRON_SKIP_BINARY_DOWNLOAD: 1
        run: |
          # update node-gyp to latest for support in detecting VS 2022 toolchain
          npm install -g node-gyp@latest
          # Resolve to node-gyp.js
          # Remove this once node-version > 17.4.x or > 16.14.0,
          # which ships with npm > 8.4.0 that has support for VS 2022 toolchain.
          $env:npm_config_node_gyp=$(Join-Path $(Get-Command node-gyp.cmd).Path "..\node_modules\node-gyp\bin\node-gyp.js" -Resolve)
          # Electron <= 13 does not ship with correct config.gypi headers,
          # remove this once we update to newer versions.
          # Refs https://github.com/nodejs/node-gyp/pull/2497
          $env:npm_config_force_process_config="true"
          yarn --frozen-lockfile --network-timeout 180000
      - name: Create node_modules archive
        if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
        run: |
          mkdir -Force .build
          node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
          mkdir -Force .build/node_modules_cache
          7z.exe a .build/node_modules_cache/cache.7z -mx3 `@.build/node_modules_list.txt

      - name: Compile and Download
        run: yarn npm-run-all --max_old_space_size=4095 -lp compile "electron x64" playwright-install download-builtin-extensions

      - name: Compile Integration Tests
        run: yarn --cwd test/integration/browser compile

      - name: Run Unit Tests (Electron)
        run: .\scripts\test.bat
{'fraction_non_alphanumeric': 0.11394258933801991, 'fraction_numerical': 0.01816051552431166, 'mean_word_length': 2.2596658711217184, 'pattern_counts': {'":': 4, '<': 5, '<?xml version=': 0, '>': 9, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1425760', 'n_tokens_mistral': 2257, 'n_tokens_neox': 2108, 'n_words': 489}