Skip to content

Commit 4559434

Browse files
chore: Introduce changesets (#2)
* add changesets packages * Implement CI logic * Update nx.json * Fix lockfile, remove rimraf --------- Co-authored-by: Kevin Van Cott <kevinvandy656@gmail.com>
1 parent 15f1ac1 commit 4559434

File tree

34 files changed

+712
-338
lines changed

34 files changed

+712
-338
lines changed

.changeset/config.json

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/config@3.1.1/schema.json",
3+
"changelog": [
4+
"@svitejs/changesets-changelog-github-compact",
5+
{ "repo": "TanStack/pacer" }
6+
],
7+
"commit": false,
8+
"access": "public",
9+
"baseBranch": "main",
10+
"updateInternalDependencies": "patch",
11+
"fixed": [],
12+
"linked": [],
13+
"ignore": []
14+
}

.changeset/shaggy-clubs-drive.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
'@tanstack/react-pacer': minor
3+
'@tanstack/solid-pacer': minor
4+
'@tanstack/pacer': minor
5+
---
6+
7+
feat: Initial release

.github/renovate.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
3+
"configMigration": true,
4+
"extends": [
5+
"config:recommended",
6+
"group:allNonMajor",
7+
"schedule:weekly",
8+
":approveMajorUpdates",
9+
":automergeMinor",
10+
":disablePeerDependencies",
11+
":maintainLockFilesMonthly",
12+
":semanticCommits",
13+
":semanticCommitTypeAll(chore)"
14+
],
15+
"ignorePresets": [":ignoreModulesAndTests"],
16+
"labels": ["dependencies"],
17+
"rangeStrategy": "bump",
18+
"postUpdateOptions": ["pnpmDedupe"],
19+
"ignoreDeps": ["@types/node", "node"]
20+
}

.github/workflows/autofix.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,14 @@ jobs:
1818
runs-on: ubuntu-latest
1919
steps:
2020
- name: Checkout
21-
uses: actions/checkout@v4
21+
uses: actions/checkout@v4.2.2
2222
- name: Setup Tools
2323
uses: tanstack/config/.github/setup@main
2424
- name: Fix formatting
2525
run: pnpm prettier:write
2626
# - name: Regenerate docs
2727
# run: pnpm docs:generate
2828
- name: Apply fixes
29-
uses: autofix-ci/action@ff86a557419858bb967097bfc916833f5647fa8c
29+
uses: autofix-ci/action@551dded8c6cc8a1054039c8bc0b8b48c51dfc6ef
3030
with:
3131
commit-message: 'ci: apply automated fixes'

.github/workflows/ci.yml

Lines changed: 0 additions & 51 deletions
This file was deleted.

.github/workflows/pr.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: pr
1+
name: PR
22

33
on:
44
pull_request:
@@ -23,28 +23,23 @@ jobs:
2323
runs-on: ubuntu-latest
2424
steps:
2525
- name: Checkout
26-
uses: actions/checkout@v4
26+
uses: actions/checkout@v4.2.2
2727
with:
2828
fetch-depth: 0
29-
- name: Start Nx Agents
30-
run: npx nx-cloud start-ci-run --distribute-on=".nx/workflows/dynamic-changesets.yaml"
3129
- name: Setup Tools
3230
uses: tanstack/config/.github/setup@main
3331
- name: Get base and head commits for `nx affected`
34-
uses: nrwl/nx-set-shas@v4
32+
uses: nrwl/nx-set-shas@v4.3.0
3533
with:
3634
main-branch-name: main
3735
- name: Run Checks
38-
run: pnpm run test:pr --parallel=3
39-
- name: Stop Nx Agents
40-
if: ${{ always() }}
41-
run: npx nx-cloud stop-all-agents
36+
run: pnpm run test:pr
4237
preview:
4338
name: Preview
4439
runs-on: ubuntu-latest
4540
steps:
4641
- name: Checkout
47-
uses: actions/checkout@v4
42+
uses: actions/checkout@v4.2.2
4843
with:
4944
fetch-depth: 0
5045
- name: Setup Tools

.github/workflows/release.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches: [main, alpha, beta, rc]
6+
7+
concurrency:
8+
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
9+
cancel-in-progress: true
10+
11+
env:
12+
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
13+
14+
permissions:
15+
contents: write
16+
id-token: write
17+
pull-requests: write
18+
19+
jobs:
20+
release:
21+
name: Release
22+
if: github.repository_owner == 'TanStack'
23+
runs-on: ubuntu-latest
24+
steps:
25+
- name: Checkout
26+
uses: actions/checkout@v4.2.2
27+
with:
28+
fetch-depth: 0
29+
- name: Setup Tools
30+
uses: tanstack/config/.github/setup@main
31+
- name: Run Tests
32+
run: pnpm run test:ci
33+
- name: Run Changesets (version or publish)
34+
uses: changesets/action@v1.4.9
35+
with:
36+
version: pnpm run changeset:version
37+
publish: pnpm run changeset:publish
38+
commit: 'ci: Version Packages'
39+
title: 'ci: Version Packages'
40+
env:
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
42+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

examples/react/debounce/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"test:types": "tsc"
1010
},
1111
"dependencies": {
12-
"@tanstack/react-pacer": "^0.1.0",
12+
"@tanstack/react-pacer": "^0.0.1",
1313
"react": "^19.0.0",
1414
"react-dom": "^19.0.0"
1515
},

examples/react/throttle/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"test:types": "tsc"
1010
},
1111
"dependencies": {
12-
"@tanstack/react-pacer": "^0.1.0",
12+
"@tanstack/react-pacer": "^0.0.1",
1313
"react": "^19.0.0",
1414
"react-dom": "^19.0.0"
1515
},

examples/react/useAsyncDebouncer/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"test:types": "tsc"
1010
},
1111
"dependencies": {
12-
"@tanstack/react-pacer": "^0.1.0",
12+
"@tanstack/react-pacer": "^0.0.1",
1313
"react": "^19.0.0",
1414
"react-dom": "^19.0.0"
1515
},

0 commit comments

Comments
 (0)