Skip to content

Commit

Permalink
Merge branch 'main' into brk.fix/active-org-cookie
Browse files Browse the repository at this point in the history
  • Loading branch information
jacekradko authored Dec 19, 2024
2 parents ff7a729 + a9234f2 commit b5199a0
Show file tree
Hide file tree
Showing 1,107 changed files with 82,811 additions and 68,849 deletions.
3 changes: 1 addition & 2 deletions .changeset/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,9 @@
"access": "public",
"baseBranch": "origin/main",
"updateInternalDependencies": "patch",
"ignore": [],
"snapshot": {
"useCalculatedVersion": true,
"prereleaseTemplate": "{tag}.v{commit}"
"prereleaseTemplate": "{tag}.v{datetime}"
},
"___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": {
"onlyUpdatePeerDependentsWhenOutOfRange": true,
Expand Down
7 changes: 0 additions & 7 deletions .changeset/curvy-ghosts-relax.md

This file was deleted.

2 changes: 2 additions & 0 deletions .changeset/eleven-months-swim.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
---
5 changes: 0 additions & 5 deletions .changeset/grumpy-rats-cheer.md

This file was deleted.

1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ packages/*/examples
package-lock.json
**/integration/templates/**/*
commitlint.config.ts
vitest.workspace.mjs
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/BUG_REPORT.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ body:
attributes:
label: Environment
render: Shell
description: Run "npx envinfo --system --browsers --binaries --npmPackages" in your project directory and paste the output here.
description: Run "pnpm dlx envinfo --system --browsers --binaries --npmPackages" in your project directory and paste the output here.
placeholder: |
You'll get an output similar to this:
Expand Down
4 changes: 2 additions & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@

## Checklist

- [ ] `npm test` runs as expected.
- [ ] `npm run build` runs as expected.
- [ ] `pnpm test` runs as expected.
- [ ] `pnpm build` runs as expected.
- [ ] (If applicable) [JSDoc comments](https://jsdoc.app/about-getting-started.html) have been added or updated for any package exports
- [ ] (If applicable) [Documentation](https://github.com/clerk/clerk-docs) has been updated

Expand Down
142 changes: 142 additions & 0 deletions .github/actions/init-blacksmith/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
name: Setup Action (Blacksmith)
description: Checkout, setup node and dependencies for Blacksmith
inputs:
node-version:
description: 'The node version to use'
required: false
default: '22'
playwright-enabled:
description: 'Enable Playwright?'
required: false
default: 'false'
turbo-summarize:
description: 'The token to use for Turbo task summaries'
required: false
default: 'false'
turbo-enabled:
description: 'Enable Turbo?'
required: false
default: 'true'
turbo-cache-dir:
description: 'The cache dir to use for Turbo'
required: false
default: './.turbo-cache'
turbo-signature:
description: 'The signature to use for Turbo'
required: false
turbo-remote-only:
description: 'Only use remote cache?'
required: false
default: 'true'
turbo-team:
description: 'The team to use for Turbo remote auth'
required: true
turbo-token:
description: 'The token to use for Turbo remote auth'
required: true
registry-url:
description: 'The registry the packages will be published to'
required: false
default: ''
verbose:
description: 'Enable verbose output'
required: false
default: 'false'

runs:
using: 'composite'
steps:
- name: Configure Turborepo
id: turbo
uses: actions/github-script@v7
env:
# envs are required to pass inputs to the script
ENABLED: ${{ inputs.turbo-enabled }}
CACHE_DIR: ${{ inputs.turbo-cache-dir }}
REMOTE_ONLY: ${{ inputs.turbo-remote-only }}
SIGNATURE: ${{ inputs.turbo-signature }}
SUMMARIZE: ${{ inputs.turbo-summarize }}
TEAM: ${{ inputs.turbo-team }}
TOKEN: ${{ inputs.turbo-token }}
VERBOSE: ${{ inputs.verbose }}
with:
script: |
const os = require('os')
const cpus =
typeof os.availableParallelism === "function"
? os.availableParallelism()
: os.cpus().length;
const { ENABLED, CACHE_DIR, SIGNATURE, REMOTE_ONLY, SUMMARIZE, TEAM, TOKEN, VERBOSE } = process.env
const ARGS = [
`--cache-dir=${CACHE_DIR}`,
`--concurrency=${cpus}`,
`--summarize=${SUMMARIZE}`,
]
if (VERBOSE === 'true') {
ARGS.push('--verbosity=2')
ARGS.push('--log-order=stream')
ARGS.push('--output-logs=full')
} else {
ARGS.push('--output-logs=new-only')
}
core.exportVariable('TURBO_ARGS',
ARGS.join(' ')
)
if (ENABLED === 'true') {
core.exportVariable('TURBO_TEAM', TEAM)
core.exportVariable('TURBO_TOKEN', TOKEN)
core.exportVariable('TURBO_REMOTE_ONLY', REMOTE_ONLY)
}
if (SIGNATURE && SIGNATURE !== '') {
core.exportVariable('TURBO_REMOTE_CACHE_SIGNATURE_KEY', SIGNATURE)
}
core.exportVariable('FORCE_COLOR', '1')
- name: Turborepo CLI Args
shell: bash
run: echo $TURBO_ARGS

- name: Install PNPM
uses: pnpm/action-setup@v4

- name: Setup NodeJS ${{ inputs.node-version }}
uses: useblacksmith/setup-node@v5
with:
cache: pnpm
node-version: ${{ inputs.node-version }}
registry-url: ${{ inputs.registry-url }}

- name: Install PNPM Dependencies
env:
CYPRESS_INSTALL_BINARY: 0
run: pnpm install
shell: bash

- name: Get Playwright Version
if: inputs.playwright-enabled == 'true'
shell: bash
id: playwright-version
run: |
VERSION=$(node -p "require('@playwright/test/package.json').version")
echo "VERSION=$VERSION" >> "$GITHUB_OUTPUT"
- name: Cache Playwright Binaries
if: inputs.playwright-enabled == 'true'
uses: useblacksmith/cache@v5
id: playwright-cache
with:
path: ~/.cache/ms-playwright
key: ${{ runner.os }}-node-${{ env.NODE_VERSION }}-playwright-${{ steps.playwright-version.outputs.VERSION }}-v2

- name: Install Playwright Browsers
if: inputs.playwright-enabled == 'true' && steps.playwright-cache.outputs.cache-hit != 'true'
shell: bash
run: |
pnpm playwright install chromium
20 changes: 13 additions & 7 deletions .github/actions/init/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ inputs:
node-version:
description: 'The node version to use'
required: false
default: '18'
default: '22'
playwright-enabled:
description: 'Enable Playwright?'
required: false
Expand Down Expand Up @@ -103,23 +103,29 @@ runs:
shell: bash
run: echo $TURBO_ARGS

- name: Install PNPM
uses: pnpm/action-setup@v4

- name: Setup NodeJS ${{ inputs.node-version }}
uses: actions/setup-node@v4
with:
cache: npm
cache-dependency-path: '**/package-lock.json'
cache: pnpm
node-version: ${{ inputs.node-version }}
registry-url: ${{ inputs.registry-url }}

- name: Install NPM Dependencies
run: npm ci --audit=false --fund=false --engine-strict=false
- name: Install PNPM Dependencies
env:
CYPRESS_INSTALL_BINARY: 0
run: pnpm install
shell: bash

- name: Get Playwright Version
if: inputs.playwright-enabled == 'true'
shell: bash
id: playwright-version
run: echo "VERSION=$(node -e "console.log($(npm ls @playwright/test --json).dependencies['@playwright/test'].version)")" >> "$GITHUB_OUTPUT"
run: |
VERSION=$(node -p "require('@playwright/test/package.json').version")
echo "VERSION=$VERSION" >> "$GITHUB_OUTPUT"
- name: Cache Playwright Binaries
if: inputs.playwright-enabled == 'true'
Expand All @@ -133,4 +139,4 @@ runs:
if: inputs.playwright-enabled == 'true' && steps.playwright-cache.outputs.cache-hit != 'true'
shell: bash
run: |
npx playwright install chromium
pnpm playwright install chromium
6 changes: 3 additions & 3 deletions .github/actions/verdaccio/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,14 @@ runs:
steps:
- name: Update NPM Registry to Verdaccio
shell: bash
run: npm set registry ${{ inputs.registry }}
run: pnpm set registry ${{ inputs.registry }}

- name: Run Verdaccio (using publish config)
shell: bash
run: |
nohup ./node_modules/.bin/verdaccio --config ./verdaccio.publish.yaml & echo "VERDACCIO_PID=$!" >> $GITHUB_ENV
sleep 5
npm config set $(echo ${{ inputs.registry }} | sed -E 's/https?://')/:_authToken secretToken
pnpm config set $(echo ${{ inputs.registry }} | sed -E 's/https?://')/:_authToken secretToken
- name: Publish to Verdaccio
shell: bash
Expand All @@ -47,4 +47,4 @@ runs:
shell: bash
run: |
nohup ./node_modules/.bin/verdaccio --config ./verdaccio.install.yaml & sleep 5
npm config set $(echo ${{ inputs.registry }} | sed -E 's/https?://')/:_authToken secretToken
pnpm config set $(echo ${{ inputs.registry }} | sed -E 's/https?://')/:_authToken secretToken
3 changes: 1 addition & 2 deletions .github/actions/version-prepatch/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@ runs:
- name: Bump prepatch version
id: bump-prepatch-version
shell: bash
run: npm version prepatch --no-git-tag-version --preid=$TAG --workspace=$PACKAGE
run: pnpm version-packages prepatch --no-git-tag-version --preid=$TAG --workspace=$PACKAGE
env:
PACKAGE: ${{ inputs.package }}
TAG: ${{ inputs.tag }}

Loading

0 comments on commit b5199a0

Please sign in to comment.