build(deps-dev): bump tap from 16.3.10 to 19.2.2 #111
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Benchmark | |
on: | |
pull_request_target: | |
types: [labeled] | |
jobs: | |
benchmark: | |
if: ${{ github.event.label.name == 'benchmark' }} | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
outputs: | |
PR-BENCH-12: ${{ steps.benchmark-pr.outputs.BENCH_RESULT12 }} | |
PR-BENCH-14: ${{ steps.benchmark-pr.outputs.BENCH_RESULT14 }} | |
PR-BENCH-16: ${{ steps.benchmark-pr.outputs.BENCH_RESULT16 }} | |
MAIN-BENCH-12: ${{ steps.benchmark-main.outputs.BENCH_RESULT12 }} | |
MAIN-BENCH-14: ${{ steps.benchmark-main.outputs.BENCH_RESULT14 }} | |
MAIN-BENCH-16: ${{ steps.benchmark-main.outputs.BENCH_RESULT16 }} | |
strategy: | |
matrix: | |
node-version: [12, 14, 16] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
ref: ${{github.event.pull_request.head.sha}} | |
repository: ${{github.event.pull_request.head.repo.full_name}} | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install | |
run: | | |
npm install --ignore-scripts | |
- name: Run benchmark | |
id: benchmark-pr | |
run: | | |
npm run --silent benchmark > ./bench-result | |
content=$(cat ./bench-result) | |
content="${content//'%'/'%25'}" | |
content="${content//$'\n'/'%0A'}" | |
content="${content//$'\r'/'%0D'}" | |
echo "::set-output name=BENCH_RESULT${{matrix.node-version}}::$content" | |
# main benchmark | |
- uses: actions/checkout@v4 | |
with: | |
ref: 'master' | |
- name: Install | |
run: | | |
npm install --ignore-scripts | |
- name: Run benchmark | |
id: benchmark-master | |
run: | | |
npm run --silent benchmark > ./bench-result | |
content=$(cat ./bench-result) | |
content="${content//'%'/'%25'}" | |
content="${content//$'\n'/'%0A'}" | |
content="${content//$'\r'/'%0D'}" | |
echo "::set-output name=BENCH_RESULT${{matrix.node-version}}::$content" | |
output-benchmark: | |
needs: [benchmark] | |
runs-on: ubuntu-latest | |
permissions: | |
pull-requests: write | |
steps: | |
- name: Comment PR | |
uses: thollander/actions-comment-pull-request@v2 | |
with: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
message: | | |
**Node**: 12 | |
**PR**: | |
``` | |
${{ needs.benchmark.outputs.PR-BENCH-12 }} | |
``` | |
**MAIN**: | |
``` | |
${{ needs.benchmark.outputs.MAIN-BENCH-12 }} | |
``` | |
--- | |
**Node**: 14 | |
**PR**: | |
``` | |
${{ needs.benchmark.outputs.PR-BENCH-14 }} | |
``` | |
**MAIN**: | |
``` | |
${{ needs.benchmark.outputs.MAIN-BENCH-14 }} | |
``` | |
--- | |
**Node**: 16 | |
**PR**: | |
``` | |
${{ needs.benchmark.outputs.PR-BENCH-16 }} | |
``` | |
**MAIN**: | |
``` | |
${{ needs.benchmark.outputs.MAIN-BENCH-16 }} | |
``` | |
- uses: actions-ecosystem/action-remove-labels@v1 | |
with: | |
labels: | | |
benchmark | |
github_token: ${{ secrets.GITHUB_TOKEN }} |