Skip to content

Commit

Permalink
feature/benchmarks (#27)
Browse files Browse the repository at this point in the history
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
  • Loading branch information
jantimon and autofix-ci[bot] authored Nov 13, 2023
1 parent 2d8eda8 commit 803c15d
Show file tree
Hide file tree
Showing 26 changed files with 108,528 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/autofix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,7 @@ jobs:
- name: Prettier Examples
run: npx prettier --write "packages/example/app/**/*.{ts,tsx,js,jsx}"

- name: Benchmarks
run: npx prettier --write "packages/benchmark/**/*.{ts,tsx}" --ignore-path "packages/benchmark/.prettierignore"

- uses: autofix-ci/action@d3e591514b99d0fca6779455ff8338516663f7cc
43 changes: 43 additions & 0 deletions .github/workflows/codspeed.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: codspeed-benchmarks

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:

jobs:
benchmarks:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Node.js
uses: actions/setup-node@v3
with:
node-version: 20
- uses: pnpm/action-setup@v2
name: Install pnpm
with:
version: 8
run_install: false
- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: pnpm install
- name: Run benchmarks
uses: CodSpeedHQ/action@v1
with:
working-directory: "packages/benchmark"
run: pnpm run codspeed
token: ${{ secrets.CODSPEED_TOKEN }}
36 changes: 36 additions & 0 deletions packages/benchmark/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env.local
.env.development.local
.env.test.local
.env.production.local

# vercel
.vercel

benchmark/lighthouse
2 changes: 2 additions & 0 deletions packages/benchmark/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
letters/*.tsx
.next
Loading

0 comments on commit 803c15d

Please sign in to comment.