Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .changeset/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
"changelog": [
"@svitejs/changesets-changelog-github-compact",
{ "repo": "TanStack/query" }
],
"commit": false,
"access": "public",
"baseBranch": "v4",
"updateInternalDependencies": "patch",
"fixed": [],
"linked": [],
"ignore": [],
"___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": {
"onlyUpdatePeerDependentsWhenOutOfRange": true
}
}
2 changes: 1 addition & 1 deletion .codesandbox/ci.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
"/examples/vue/basic"
],
"packages": ["packages/**"],
"node": "16"
"node": "18"
}
60 changes: 0 additions & 60 deletions .github/workflows/ci.yml

This file was deleted.

44 changes: 15 additions & 29 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: pr

on: [pull_request]
on:
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
Expand All @@ -17,39 +18,31 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4.2.2
uses: actions/checkout@v6.0.1
with:
fetch-depth: 0
- name: Start Nx Agents
run: npx nx-cloud start-ci-run
- name: Setup Tools
uses: tanstack/config/.github/setup@main
- name: Get base and head commits for `nx affected`
uses: nrwl/[email protected]
uses: nrwl/[email protected]
with:
main-branch-name: v4
- name: Run Tests
run: pnpm run test:pr --parallel=3
- name: Stop Agents
run: npx nx-cloud stop-all-agents
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
format:
name: Format
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4.2.2
uses: actions/checkout@v6.0.1
with:
fetch-depth: 0
- name: Setup pnpm
uses: pnpm/[email protected]
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version-file: .nvmrc
cache: pnpm
cache-dependency-path: pnpm-lock.yaml
- name: Install dependencies
run: pnpm --filter "./packages/**" --filter query --prefer-offline install
- name: Setup Tools
uses: tanstack/config/.github/setup@main
- name: Run prettier
run: pnpm run test:format
test-react-version:
Expand All @@ -60,22 +53,15 @@ jobs:
react-version: [17, 18]
steps:
- name: Checkout
uses: actions/checkout@v4.2.2
uses: actions/checkout@v6.0.1
with:
fetch-depth: 0
ref: ${{ github.head_ref }}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Setup pnpm
uses: pnpm/[email protected]
- uses: actions/setup-node@v3
- name: Setup Tools
uses: tanstack/config/.github/setup@main
- name: Get base and head commits for `nx affected`
uses: nrwl/[email protected]
with:
node-version-file: .nvmrc
cache: pnpm
cache-dependency-path: pnpm-lock.yaml
- name: Install dependencies
run: pnpm --filter "./packages/**" --filter query --prefer-offline install
- name: Derive appropriate SHAs for base and head for `nx affected` commands
uses: nrwl/nx-set-shas@v2
main-branch-name: v4
- name: Run Tests for React ${{ matrix.react-version }}
uses: nick-fields/[email protected]
with:
Expand Down
39 changes: 39 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: ci

on:
push:
branches: [main, alpha, beta, rc, v4]

concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
cancel-in-progress: true

env:
NX_CLOUD_DISTRIBUTED_EXECUTION: false
NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
NX_CLOUD_AUTH_TOKEN: ${{ secrets.NX_CLOUD_AUTH_TOKEN }}

jobs:
release:
name: Release
if: github.repository_owner == 'TanStack'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
with:
fetch-depth: 0
- name: Setup Tools
uses: tanstack/config/.github/setup@main
- name: Run Tests
run: pnpm run test:ci
- name: Run Changesets (version or publish)
id: changesets
uses: changesets/[email protected]
with:
version: pnpm run changeset:version
publish: pnpm run changeset:publish
commit: 'ci: Version Packages (v4)'
title: 'ci: Version Packages (v4)'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25 changes: 15 additions & 10 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,10 @@ package-lock.json
yarn.lock

# builds
types
*/**/build
*/**/dist
*/**/lib
*/**/es
artifacts
.rpt2_cache
build
coverage
*.tgz
dist
dist-ts

# misc
.DS_Store
Expand All @@ -35,12 +30,22 @@ stats-hydration.json
stats.json
stats.html
.vscode/settings.json
.vscode/mcp.json
.cursor/rules
.github/instructions/nx.instructions.md

*.log
*.tsbuildinfo
.DS_Store
.angular
.cache
.idea
.nx/cache
.nx/workspace-data
nx-cloud.env
.pnpm-store
.svelte-kit
.tsup
.vinxi
temp

vite.config.js.timestamp-*
vite.config.ts.timestamp-*
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
**/build
**/coverage
**/dist
**/dist-ts
**/codemods/**/__testfixtures__
53 changes: 22 additions & 31 deletions nx.json
Original file line number Diff line number Diff line change
@@ -1,31 +1,11 @@
{
"$schema": "./node_modules/nx/schemas/nx-schema.json",
"affected": {
"defaultBase": "main"
},
"tasksRunnerOptions": {
"default": {
"runner": "nx-cloud",
"options": {
"cacheableOperations": [
"test:lib",
"test:eslint",
"test:types",
"test:build",
"build:types",
"build",
"rollup"
],
"parallel": 5,
"accessToken": "ZDdkNDA4MGEtYjNmYi00MWI4LWE1N2QtYTdlNmYxMGJlZWM2fHJlYWQ="
}
}
},
"defaultBase": "main",
"pluginsConfig": {
"@nrwl/js": {
"analyzeSourceFiles": false
}
"defaultBase": "v4",
"nxCloudId": "6412c827e6da5d7b4a0b1fe3",
"useInferencePlugins": false,
"parallel": 5,
"tui": {
"enabled": false
},
"namedInputs": {
"globalBuildAffectingConfig": [
Expand Down Expand Up @@ -59,30 +39,41 @@
"targetDefaults": {
"test:lib": {
"outputs": ["{projectRoot}/coverage"],
"inputs": ["default", "^public"]
"inputs": ["default", "^public"],
"cache": true
},
"test:eslint": {
"inputs": ["default", "^public"]
"inputs": ["default", "^public"],
"cache": true
},
"test:types": {
"outputs": [
"{projectRoot}/build/**/*.d.ts",
"{projectRoot}/build/.tsbuildinfo"
],
"inputs": ["default", "^public"],
"dependsOn": ["^test:types"]
"dependsOn": ["^test:types"],
"cache": true
},
"build:types": {
"outputs": [
"{projectRoot}/build/**/*.d.ts",
"{projectRoot}/build/.tsbuildinfo"
],
"inputs": ["default", "^public"],
"dependsOn": ["^build:types"]
"dependsOn": ["^build:types"],
"cache": true
},
"test:build": {
"dependsOn": ["build"],
"inputs": ["^public"]
"inputs": ["^public"],
"cache": true
},
"build": {
"cache": true
},
"rollup": {
"cache": true
}
}
}
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"type": "git",
"url": "https://github.com/TanStack/query.git"
},
"packageManager": "pnpm@8.5.1",
"packageManager": "pnpm@9.5.0",
"scripts": {
"clean": "pnpm --filter \"./packages/**\" run clean",
"preinstall": "node -e \"if(process.env.CI == 'true') {console.log('Skipping preinstall...'); process.exit(1)}\" || npx -y only-allow pnpm",
Expand Down Expand Up @@ -74,8 +74,7 @@
"eslint-plugin-react-hooks": "^4.6.0",
"expect-type": "^1.2.1",
"jest": "^27.5.1",
"nx": "16.7.4",
"nx-cloud": "16.3.0",
"nx": "22.3.3",
"prettier": "^2.6.2",
"prettier-plugin-svelte": "^2.9.0",
"react": "^19.1.1",
Expand Down
Loading
Loading