diff --git a/.gitattributes b/.gitattributes index 03d67d7..6fcbed3 100644 --- a/.gitattributes +++ b/.gitattributes @@ -8,3 +8,5 @@ /src/_grapheme_table.js linguist-generated /src/_incb_table.js linguist-generated /test/_unicode_testdata.js linguist-generated + +/prebuilt/* linguist-vendored diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2f1280e..261a07b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,8 +44,29 @@ jobs: - name: Install Dependencies run: yarn install --immutable + - uses: actions/cache@v4 + id: cache-prebuilt-node + with: + key: node-v24.0.0-pre-linux-x64_icu76.1 + path: prebuilt/node-v24.0.0-pre-linux-x64_icu76.1 + + - name: Download Prebuilt Node.js with ICU 76.1 + if: steps.cache-prebuilt-node.cache-hit != 'true' + run: | + sudo apt-get update && sudo apt-get upgrade g++ + ls -al /lib/x86_64-linux-gnu + export PREBUILT_BINARY="prebuilt/node-v24.0.0-pre-linux-x64_icu76.1" + mkdir -p "$(dirname $PREBUILT_BINARY)" + curl -fsSL -o "$PREBUILT_BINARY" \ + "https://github-actions-assets.cometkim.dev/$PREBUILT_BINARY" + chmod +x "$PREBUILT_BINARY" + echo "PREBUILT_BINARY=$PREBUILT_BINARY" >> $GITHUB_ENV + - name: Execute Tests - run: yarn test:coverage + run: | + $PREBUILT_BINARY \ + --test --test-reporter spec --test-reporter-destination=stdout \ + --experimental-test-coverage --test-reporter=lcov --test-reporter-destination=lcov.info - name: Upload coverage reports to Codecov uses: codecov/codecov-action@v4.0.1