Skip to content

Commit

Permalink
chore: CI support node18 (#3093) (#3141)
Browse files Browse the repository at this point in the history
Co-authored-by: KATT <alexander@n1s.se>
  • Loading branch information
sun0day and KATT committed Nov 23, 2022
1 parent a3683d6 commit 039aa53
Show file tree
Hide file tree
Showing 20 changed files with 34 additions and 34 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/examples-old-nodes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
matrix:
dir: [.interop/next-prisma-starter]
# start example with:
node-start: ['14.x']
node-start: ['14.x', '16.x']
os: [ubuntu-latest]
steps:
- uses: actions/checkout@v3
Expand All @@ -22,7 +22,7 @@ jobs:

- uses: actions/setup-node@v3
with:
node-version: 16.x
node-version: 18.x

- name: Get pnpm store directory
id: pnpm-cache
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
standalone-server,
.test/big-router-declaration,
]
node-start: ['16.x']
node-start: ['18.x']
os: [ubuntu-latest]
steps:
- uses: actions/checkout@v3
Expand All @@ -53,7 +53,7 @@ jobs:

- uses: actions/setup-node@v3
with:
node-version: 16.x
node-version: 18.x

- name: Get pnpm store directory
id: pnpm-cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:

- uses: actions/setup-node@v3
with:
node-version: 16.x
node-version: 18.x

- name: Get pnpm store directory
id: pnpm-cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:

strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]

steps:
Expand Down
4 changes: 2 additions & 2 deletions examples/.interop/cloudflare-workers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"type": "module",
"scripts": {
"dev": "wrangler dev",
"test-dev": "start-server-and-test 'wrangler dev --local' 8787 'tsx src/client.ts'"
"test-dev": "start-server-and-test 'wrangler dev --local' http://127.0.0.1:8787 'tsx src/client.ts'"
},
"dependencies": {
"@trpc/client": "^10.1.0",
Expand All @@ -24,4 +24,4 @@
"publishConfig": {
"access": "restricted"
}
}
}
2 changes: 1 addition & 1 deletion examples/.interop/cloudflare-workers/src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ global.fetch = fetch as any;
const sleep = (ms = 100) => new Promise((resolve) => setTimeout(resolve, ms));

async function main() {
const url = 'http://localhost:8787';
const url = 'http://127.0.0.1:8787';

const client = createTRPCClient<AppRouter>({
links: [loggerLink(), httpBatchLink({ url })],
Expand Down
2 changes: 1 addition & 1 deletion examples/.interop/fastify-server/src/client/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export function createClient(
) {
const port = opts.port ?? 3000;
const prefix = opts.prefix ?? '/trpc';
const host = `127.0.0.1:${port}${prefix}`;
const host = `localhost:${port}${prefix}`;
const wsClient = createWSClient({ url: `ws://${host}` });
const client = createTRPCClient<AppRouter>({
links: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]
steps:
- name: Checkout repo
Expand Down
6 changes: 3 additions & 3 deletions examples/.interop/next-prisma-starter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
"test": "run-s test:*",
"test:unit": "vitest run",
"test:e2e": "playwright test",
"test-dev": "start-server-and-test 'next dev' 3000 test",
"test-start": "start-server-and-test start 3000 test",
"test-dev": "start-server-and-test 'next dev' http://127.0.0.1:3000 test",
"test-start": "start-server-and-test start http://127.0.0.1:3000 test",
"postinstall": "prisma generate"
},
"prisma": {
Expand Down Expand Up @@ -77,4 +77,4 @@
"publishConfig": {
"access": "restricted"
}
}
}
2 changes: 1 addition & 1 deletion examples/.interop/next-prisma-starter/src/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ function getBaseUrl() {
}

// assume localhost
return `http://localhost:${process.env.PORT ?? 3000}`;
return `http://127.0.0.1:${process.env.PORT ?? 3000}`;
}

export default withTRPC<AppRouter>({
Expand Down
6 changes: 3 additions & 3 deletions examples/.interop/next-prisma-todomvc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
"migrate-dev": "prisma migrate dev",
"migrate": "prisma migrate deploy",
"test": "playwright test",
"test-dev": "start-server-and-test 'next dev' 3000 test",
"test-start": "start-server-and-test start 3000 test",
"test-dev": "start-server-and-test 'next dev' http://127.0.0.1:3000 test",
"test-start": "start-server-and-test start http://127.0.0.1:3000 test",
"postinstall": "prisma generate"
},
"dependencies": {
Expand Down Expand Up @@ -54,4 +54,4 @@
"publishConfig": {
"access": "restricted"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]
steps:
- name: Checkout repo
Expand Down
6 changes: 3 additions & 3 deletions examples/.test/ssg/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
"build": "next build",
"start": "next start",
"test:e2e": "playwright test",
"test-dev": "start-server-and-test dev 3000 test:e2e",
"test-start": "start-server-and-test start 3000 test:e2e"
"test-dev": "start-server-and-test dev http://127.0.0.1:3000 test:e2e",
"test-start": "start-server-and-test start http://127.0.0.1:3000 test:e2e"
},
"dependencies": {
"@tanstack/react-query": "^4.3.8",
Expand All @@ -30,4 +30,4 @@
"start-server-and-test": "^1.12.0",
"typescript": "^4.8.3"
}
}
}
4 changes: 2 additions & 2 deletions examples/cloudflare-workers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"type": "module",
"scripts": {
"dev": "wrangler dev",
"test-dev": "start-server-and-test 'wrangler dev --local' 8787 'tsx src/client.ts'"
"test-dev": "start-server-and-test 'wrangler dev --local' http://127.0.0.1:8787 'tsx src/client.ts'"
},
"dependencies": {
"@trpc/client": "^10.1.0",
Expand All @@ -25,4 +25,4 @@
"publishConfig": {
"access": "restricted"
}
}
}
2 changes: 1 addition & 1 deletion examples/cloudflare-workers/src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ globalThis.fetch = fetch as any;
const sleep = (ms = 100) => new Promise((resolve) => setTimeout(resolve, ms));

async function main() {
const url = 'http://localhost:8787';
const url = 'http://127.0.0.1:8787';

const client = createTRPCClient<AppRouter>({
links: [loggerLink(), httpBatchLink({ url })],
Expand Down
2 changes: 1 addition & 1 deletion examples/next-prisma-starter/.github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]
steps:
- name: Checkout repo
Expand Down
6 changes: 3 additions & 3 deletions examples/next-prisma-starter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
"test": "run-s test:*",
"test:unit": "vitest run",
"test:e2e": "playwright test",
"test-dev": "start-server-and-test 'next dev' 3000 test",
"test-start": "start-server-and-test start 3000 test",
"test-dev": "start-server-and-test 'next dev' http://127.0.0.1:3000 test",
"test-start": "start-server-and-test start http://127.0.0.1:3000 test",
"postinstall": "prisma generate"
},
"prisma": {
Expand Down Expand Up @@ -76,4 +76,4 @@
"publishConfig": {
"access": "restricted"
}
}
}
2 changes: 1 addition & 1 deletion examples/next-prisma-starter/src/utils/trpc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function getBaseUrl() {
}

// assume localhost
return `http://localhost:${process.env.PORT ?? 3000}`;
return `http://127.0.0.1:${process.env.PORT ?? 3000}`;
}

/**
Expand Down
6 changes: 3 additions & 3 deletions examples/next-prisma-todomvc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
"migrate-dev": "prisma migrate dev",
"migrate": "prisma migrate deploy",
"test": "playwright test",
"test-dev": "start-server-and-test 'next dev' 3000 test",
"test-start": "start-server-and-test start 3000 test",
"test-dev": "start-server-and-test 'next dev' http://127.0.0.1:3000 test",
"test-start": "start-server-and-test start http://127.0.0.1:3000 test",
"postinstall": "prisma generate"
},
"dependencies": {
Expand Down Expand Up @@ -54,4 +54,4 @@
"publishConfig": {
"access": "restricted"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]
steps:
- name: Checkout repo
Expand Down

1 comment on commit 039aa53

@vercel
Copy link

@vercel vercel bot commented on 039aa53 Nov 23, 2022

Choose a reason for hiding this comment

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

Successfully deployed to the following URLs:

next-prisma-starter – ./examples/next-prisma-starter

next-prisma-starter-trpc.vercel.app
nextjs.trpc.io
next-prisma-starter-git-main-trpc.vercel.app

Please sign in to comment.