Skip to content

Commit

Permalink
release: 2023-09-26 (#193)
Browse files Browse the repository at this point in the history
PR-URL: #193
Co-authored-by: Joe Karow <[email protected]>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
  • Loading branch information
3 people authored Sep 26, 2023
2 parents 4da1877 + 5f0d3e2 commit 14c359c
Show file tree
Hide file tree
Showing 24 changed files with 1,441 additions and 2,112 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/chromatic.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
CI: true
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
with:
fetch-depth: 0
- uses: pnpm/action-setup@d882d12c64e032187b2edb46d3a0d003b7a43598 # v2.4.0
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: ⤵️ Check out code from GitHub
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- name: 🏗 Initialize CodeQL
uses: github/codeql-action/init@6a28655e3dcb49cb0840ea372fd6d17733edd8a4 # v2
- name: 🚀 Perform CodeQL Analysis
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: ⤵️ Check out code from GitHub
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
- name: 🚀 Run Label Syncer
uses: micnncim/action-label-syncer@3abd5ab72fda571e69fffd97bd4e0033dd5f495c # v1.3.0
env:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
steps:
# Setup steps
- name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
with:
ref: ${{ github.head_ref }}
fetch-depth: 0
Expand Down
130 changes: 130 additions & 0 deletions .github/workflows/nextjs_bundle_analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
# Copyright (c) HashiCorp, Inc.
# SPDX-License-Identifier: MPL-2.0

name: 'Next.js Bundle Analysis'

on:
pull_request:
push:
branches:
- main # change this if your default branch is named differently
workflow_dispatch:

defaults:
run:
# change this if your nextjs app does not live at the root of the repo
working-directory: ./

permissions:
contents: read # for checkout repository
actions: read # for fetching base branch bundle stats
pull-requests: write # for comments

jobs:
analyze:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4

- uses: pnpm/action-setup@d882d12c64e032187b2edb46d3a0d003b7a43598 # v2.4.0
name: Install pnpm
id: pnpm-install
with:
version: 8
run_install: false

- name: Install Node.js
uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3
with:
node-version: 18
cache: pnpm

- name: Install dependencies
run: pnpm install

- name: Restore next build
uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 # v3
id: restore-build-cache
env:
cache-name: cache-next-build
with:
# if you use a custom build directory, replace all instances of `.next` in this file with your build directory
# ex: if your app builds to `dist`, replace `.next` with `dist`
path: .next/cache
# change this if you prefer a more strict cache
key: ${{ runner.os }}-build-${{ env.cache-name }}

- name: Build next.js app
# change this if your site requires a custom build command
run: ./node_modules/.bin/next build
env:
POSTGRES_PRISMA_URL: ${{ secrets.POSTGRES_PRISMA_URL }}

# Here's the first place where next-bundle-analysis' own script is used
# This step pulls the raw bundle stats for the current bundle
- name: Analyze bundle
run: npx -p nextjs-bundle-analysis report

- name: Upload bundle
uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # v3
with:
name: bundle
path: .next/analyze/__bundle_analysis.json

- name: Download base branch bundle stats
uses: dawidd6/action-download-artifact@246dbf436b23d7c49e21a7ab8204ca9ecd1fe615 # v2
if: success() && github.event.number
with:
workflow: nextjs_bundle_analysis.yml
branch: ${{ github.event.pull_request.base.ref }}
path: .next/analyze/base

# And here's the second place - this runs after we have both the current and
# base branch bundle stats, and will compare them to determine what changed.
# There are two configurable arguments that come from package.json:
#
# - budget: optional, set a budget (bytes) against which size changes are measured
# it's set to 350kb here by default, as informed by the following piece:
# https://infrequently.org/2021/03/the-performance-inequality-gap/
#
# - red-status-percentage: sets the percent size increase where you get a red
# status indicator, defaults to 20%
#
# Either of these arguments can be changed or removed by editing the `nextBundleAnalysis`
# entry in your package.json file.
- name: Compare with base branch bundle
if: success() && github.event.number
run: ls -laR .next/analyze/base && npx -p nextjs-bundle-analysis compare

- name: Get Comment Body
id: get-comment-body
if: success() && github.event.number
# https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#multiline-strings
run: |
echo "body<<EOF" >> $GITHUB_OUTPUT
echo "$(cat .next/analyze/__bundle_analysis_comment.txt)" >> $GITHUB_OUTPUT
echo EOF >> $GITHUB_OUTPUT
- name: Find Comment
uses: peter-evans/find-comment@a54c31d7fa095754bfef525c0c8e5e5674c4b4b1 # v2
if: success() && github.event.number
id: fc
with:
issue-number: ${{ github.event.number }}
body-includes: '<!-- __NEXTJS_BUNDLE -->'

- name: Create Comment
uses: peter-evans/create-or-update-comment@c6c9a1a66007646a28c153e2a8580a5bad27bcfa # v3
if: success() && github.event.number && steps.fc.outputs.comment-id == 0
with:
issue-number: ${{ github.event.number }}
body: ${{ steps.get-comment-body.outputs.body }}

- name: Update Comment
uses: peter-evans/create-or-update-comment@c6c9a1a66007646a28c153e2a8580a5bad27bcfa # v3
if: success() && github.event.number && steps.fc.outputs.comment-id != 0
with:
issue-number: ${{ github.event.number }}
body: ${{ steps.get-comment-body.outputs.body }}
comment-id: ${{ steps.fc.outputs.comment-id }}
edit-mode: replace
2 changes: 1 addition & 1 deletion .husky/post-merge
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ fi
}

# Run `pnpm install` if package.json changed.
check_changed "package.json pnpm-lock.yaml" "tsx ./.lib/runInstall.ts"
check_changed "package.json pnpm-lock.yaml" "pnpm notify:install"
2 changes: 1 addition & 1 deletion next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import i18nConfig from './next-i18next.config.js'
* Run `build` or `dev` with `SKIP_ENV_VALIDATION` to skip env validation. This is especially useful for
* Docker builds.
*/
// eslint-disable-next-line turbo/no-undeclared-env-vars

!process.env.SKIP_ENV_VALIDATION && (await import('./src/env/server.mjs'))

const withRoutes = nextRoutes({ outDir: 'src/types' })
Expand Down
77 changes: 34 additions & 43 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
"lint": "next lint",
"lint:fix": "next lint --fix",
"lint:staged": "lint-staged",
"notify:install": "tsx ./.lib/runInstall.ts",
"prepare": "tsx ./.lib/prepare.ts",
"start": "next start",
"with-env": "dotenv -e ./.env --"
Expand All @@ -35,43 +36,26 @@
"@emotion/server": "11.11.0",
"@mantine/carousel": "6.0.21",
"@mantine/core": "6.0.21",
"@mantine/dates": "6.0.21",
"@mantine/dropzone": "6.0.21",
"@mantine/form": "6.0.21",
"@mantine/hooks": "6.0.21",
"@mantine/modals": "6.0.21",
"@mantine/next": "6.0.21",
"@mantine/notifications": "6.0.21",
"@mantine/nprogress": "6.0.21",
"@mantine/prism": "6.0.21",
"@mantine/spotlight": "6.0.21",
"@mantine/tiptap": "6.0.21",
"@mantine/utils": "6.0.21",
"@next-auth/prisma-adapter": "1.0.7",
"@next/bundle-analyzer": "13.5.1",
"@next/bundle-analyzer": "13.5.3",
"@prisma/client": "5.3.1",
"@tabler/icons-react": "2.34.0",
"@tabler/icons-react": "2.35.0",
"@tanstack/react-query": "4.35.3",
"@tanstack/react-query-devtools": "4.35.3",
"@tiptap/extension-link": "2.1.10",
"@tiptap/react": "2.1.10",
"@tiptap/starter-kit": "2.1.10",
"@trpc/client": "10.38.3",
"@trpc/next": "10.38.3",
"@trpc/react-query": "10.38.3",
"@trpc/server": "10.38.3",
"@trpc/client": "10.38.4",
"@trpc/next": "10.38.4",
"@trpc/react-query": "10.38.4",
"@trpc/server": "10.38.4",
"@vercel/analytics": "1.0.2",
"dayjs": "1.11.10",
"embla-carousel-auto-height": "7.1.0",
"embla-carousel-react": "7.1.0",
"eslint-config-prettier": "9.0.0",
"i18next": "23.5.1",
"i18next-browser-languagedetector": "7.1.0",
"i18next-http-backend": "2.2.2",
"luxon": "3.4.3",
"nanoid": "5.0.1",
"next": "13.5.1",
"next-auth": "4.23.1",
"next": "13.5.3",
"next-i18next": "14.0.3",
"next-sitemap": "4.2.3",
"nextjs-routes": "2.0.1",
Expand All @@ -85,64 +69,71 @@
"devDependencies": {
"@faker-js/faker": "7.6.0",
"@paralleldrive/cuid2": "2.2.2",
"@storybook/addon-a11y": "7.4.2",
"@storybook/addon-essentials": "7.4.2",
"@storybook/addon-interactions": "7.4.2",
"@storybook/addon-links": "7.4.2",
"@storybook/addon-viewport": "7.4.2",
"@storybook/blocks": "7.4.2",
"@storybook/nextjs": "7.4.2",
"@storybook/react": "7.4.2",
"@storybook/addon-a11y": "7.4.5",
"@storybook/addon-essentials": "7.4.5",
"@storybook/addon-interactions": "7.4.5",
"@storybook/addon-links": "7.4.5",
"@storybook/addon-viewport": "7.4.5",
"@storybook/blocks": "7.4.5",
"@storybook/nextjs": "7.4.5",
"@storybook/react": "7.4.5",
"@storybook/testing-library": "0.2.1",
"@tomfreudenberg/next-auth-mock": "0.5.6",
"@types/luxon": "3.3.2",
"@types/node": "18.17.17",
"@types/node": "18.18.0",
"@types/prettier": "2.7.3",
"@types/react": "18.2.22",
"@types/react": "18.2.23",
"@types/react-dom": "18.2.7",
"@types/umami": "0.1.3",
"@typescript-eslint/eslint-plugin": "6.7.2",
"@typescript-eslint/parser": "6.7.2",
"@typescript-eslint/eslint-plugin": "6.7.3",
"@typescript-eslint/parser": "6.7.3",
"boxen": "7.1.1",
"chromatic": "7.2.0",
"dotenv": "16.3.1",
"dotenv-cli": "7.3.0",
"eslint": "8.49.0",
"eslint-config-next": "13.5.1",
"eslint": "8.50.0",
"eslint-config-next": "13.5.3",
"eslint-config-prettier": "9.0.0",
"eslint-formatter-github": "1.1.4",
"eslint-import-resolver-typescript": "3.6.0",
"eslint-import-resolver-typescript": "3.6.1",
"eslint-plugin-codegen": "0.17.0",
"eslint-plugin-i18next": "6.0.3",
"eslint-plugin-import": "2.28.1",
"eslint-plugin-node": "11.1.0",
"eslint-plugin-react": "7.33.2",
"eslint-plugin-storybook": "0.6.13",
"eslint-plugin-storybook": "0.6.14",
"eslint-plugin-turbo": "1.10.14",
"husky": "8.0.3",
"lint-staged": "14.0.1",
"listr2": "6.6.1",
"luxon": "3.4.3",
"merge-anything": "5.1.7",
"prettier": "3.0.3",
"prettier-plugin-jsdoc": "1.0.2",
"prettier-plugin-packagejson": "2.4.5",
"prettier-plugin-prisma": "5.0.0",
"prisma": "5.3.1",
"react-docgen-typescript": "2.2.2",
"storybook": "7.4.2",
"tsx": "3.12.10",
"storybook": "7.4.5",
"tsx": "3.13.0",
"turbo": "1.10.14",
"type-fest": "4.3.1",
"typescript": "5.2.2"
},
"packageManager": "pnpm@8.7.6",
"packageManager": "pnpm@8.8.0",
"engines": {
"node": "^18.0.0",
"pnpm": "^8.0.0"
},
"ct3aMetadata": {
"initVersion": "7.3.2"
},
"nextBundleAnalysis": {
"budget": 358400,
"budgetPercentIncreaseRed": 20,
"minimumChangeThreshold": 0,
"showDetails": true
},
"pnpm": {
"overrides": {
"eslint-plugin-import": "npm:eslint-plugin-i"
Expand Down
Loading

1 comment on commit 14c359c

@vercel
Copy link

@vercel vercel bot commented on 14c359c Sep 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.