Skip to content

Commit d815ecd

Browse files
committed
up deps
1 parent 078ec9f commit d815ecd

File tree

7 files changed

+2260
-2321
lines changed

7 files changed

+2260
-2321
lines changed

.github/workflows/changesets.yml

Lines changed: 28 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
name: changesets
2+
13
on:
24
push:
35
branches:
@@ -6,36 +8,38 @@ on:
68
- .changeset/**/*
79
workflow_dispatch:
810

9-
name: changesets
11+
permissions:
12+
contents: read
13+
14+
concurrency:
15+
group: release-${{ github.ref }}
16+
cancel-in-progress: true
1017

1118
jobs:
1219
changesets:
13-
name: create pr / publish
1420
runs-on: ubuntu-latest
1521

1622
permissions:
17-
contents: write
18-
pull-requests: write
19-
id-token: write
23+
contents: write # for changesets to push tags
24+
pull-requests: write # for changesets to create/update prs
25+
id-token: write # for auth with npm oidc
2026

2127
steps:
22-
- name: Checkout Repo
23-
uses: actions/checkout@v4
28+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2429
with:
25-
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
2630
fetch-depth: 0
31+
persist-credentials: false
2732

28-
- uses: actions/setup-node@v4
33+
- uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0
34+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6
2935
with:
30-
node-version: 22.22.0
31-
32-
- run: corepack enable
36+
node-version: 25
3337

3438
- name: find pnpm cache path
3539
id: cache
36-
run: echo "path=$(pnpm store path)" >> $GITHUB_OUTPUT
40+
run: echo "path=$(pnpm store path)" >> "$GITHUB_OUTPUT"
3741

38-
- uses: actions/cache@v4
42+
- uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
3943
with:
4044
path: ${{ steps.cache.outputs.path }}
4145
key: v1-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
@@ -45,13 +49,20 @@ jobs:
4549
- name: Install dependencies
4650
run: pnpm install --frozen-lockfile
4751

52+
- name: Build
53+
run: node --run build
54+
55+
- name: update npm
56+
run: npm i -g npm
57+
4858
- name: Update release PR / Publish packages to `npm`
49-
uses: changesets/action@v1
59+
id: changesets
60+
uses: changesets/action@6a0a831ff30acef54f2c6aa1cbbc1096b066edaf # v1.7.0
5061
with:
5162
title: Release
5263
commit: Release new version
53-
publish: pnpm release
64+
publish: pnpm changeset publish
5465
env:
5566
NPM_CONFIG_PROVENANCE: true
56-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
5767
GITHUB_TOKEN: ${{ secrets.CUSTOM_GITHUB_TOKEN }}
68+
NPM_TOKEN: "" # Workaround. See https://github.com/changesets/changesets/issues/1152#issuecomment-3190884868

.github/workflows/ci.yml

Lines changed: 51 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -6,26 +6,32 @@ on:
66
- main
77
pull_request:
88

9+
permissions:
10+
contents: read
11+
12+
concurrency:
13+
group: ci-${{ github.ref }}
14+
cancel-in-progress: true
15+
916
jobs:
10-
lint:
17+
build:
1118
runs-on: ubuntu-latest
1219

1320
steps:
14-
- uses: actions/checkout@v4
21+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
22+
with:
23+
persist-credentials: false
1524

16-
- uses: actions/setup-node@v4
25+
- uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0
26+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6
1727
with:
1828
node-version: 18
1929

20-
- run: npm i -g corepack
21-
22-
- run: corepack enable
23-
2430
- name: find pnpm cache path
2531
id: cache
26-
run: echo "path=$(pnpm store path)" >> $GITHUB_OUTPUT
32+
run: echo "path=$(pnpm store path)" >> "$GITHUB_OUTPUT"
2733

28-
- uses: actions/cache@v4
34+
- uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
2935
with:
3036
path: ${{ steps.cache.outputs.path }}
3137
key: v1-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
@@ -35,27 +41,26 @@ jobs:
3541
- name: Install dependencies
3642
run: pnpm install --frozen-lockfile
3743

38-
- run: pnpm lint
44+
- run: node --run build
3945

40-
typecheck:
46+
lint:
4147
runs-on: ubuntu-latest
4248

4349
steps:
44-
- uses: actions/checkout@v4
50+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
51+
with:
52+
persist-credentials: false
4553

46-
- uses: actions/setup-node@v4
54+
- uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0
55+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6
4756
with:
4857
node-version: 18
4958

50-
- run: npm i -g corepack
51-
52-
- run: corepack enable
53-
5459
- name: find pnpm cache path
5560
id: cache
56-
run: echo "path=$(pnpm store path)" >> $GITHUB_OUTPUT
61+
run: echo "path=$(pnpm store path)" >> "$GITHUB_OUTPUT"
5762

58-
- uses: actions/cache@v4
63+
- uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
5964
with:
6065
path: ${{ steps.cache.outputs.path }}
6166
key: v1-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
@@ -65,27 +70,26 @@ jobs:
6570
- name: Install dependencies
6671
run: pnpm install --frozen-lockfile
6772

68-
- run: pnpm typecheck
73+
- run: node --run lint
6974

70-
test:
75+
typecheck:
7176
runs-on: ubuntu-latest
7277

7378
steps:
74-
- uses: actions/checkout@v4
75-
76-
- uses: actions/setup-node@v4
79+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
7780
with:
78-
node-version: 18
79-
80-
- run: npm i -g corepack
81+
persist-credentials: false
8182

82-
- run: corepack enable
83+
- uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0
84+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6
85+
with:
86+
node-version: 20
8387

8488
- name: find pnpm cache path
8589
id: cache
86-
run: echo "path=$(pnpm store path)" >> $GITHUB_OUTPUT
90+
run: echo "path=$(pnpm store path)" >> "$GITHUB_OUTPUT"
8791

88-
- uses: actions/cache@v4
92+
- uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
8993
with:
9094
path: ${{ steps.cache.outputs.path }}
9195
key: v1-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
@@ -95,33 +99,26 @@ jobs:
9599
- name: Install dependencies
96100
run: pnpm install --frozen-lockfile
97101

98-
- run: pnpm test
102+
- run: node --run typecheck
99103

100-
- uses: codecov/codecov-action@v5
101-
with:
102-
files: node_modules/.coverage/lcov.info
103-
fail_ci_if_error: true
104-
token: ${{ secrets.CODECOV_TOKEN }}
105-
106-
build:
104+
test:
107105
runs-on: ubuntu-latest
108106

109107
steps:
110-
- uses: actions/checkout@v4
111-
112-
- uses: actions/setup-node@v4
108+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
113109
with:
114-
node-version: 18
115-
116-
- run: npm i -g corepack
110+
persist-credentials: false
117111

118-
- run: corepack enable
112+
- uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # v4.2.0
113+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6
114+
with:
115+
node-version: 20
119116

120117
- name: find pnpm cache path
121118
id: cache
122-
run: echo "path=$(pnpm store path)" >> $GITHUB_OUTPUT
119+
run: echo "path=$(pnpm store path)" >> "$GITHUB_OUTPUT"
123120

124-
- uses: actions/cache@v4
121+
- uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
125122
with:
126123
path: ${{ steps.cache.outputs.path }}
127124
key: v1-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
@@ -131,4 +128,10 @@ jobs:
131128
- name: Install dependencies
132129
run: pnpm install --frozen-lockfile
133130

134-
- run: pnpm build
131+
- run: node --run test
132+
133+
- uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
134+
with:
135+
files: node_modules/.coverage/lcov.info
136+
fail_ci_if_error: true
137+
token: ${{ secrets.CODECOV_TOKEN }}

.github/workflows/tflint.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@ jobs:
1717
runs-on: ubuntu-latest
1818

1919
steps:
20-
- uses: actions/checkout@v4
20+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2121

22-
- uses: actions/cache@v4
22+
- uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
2323
with:
2424
path: ~/.tflint.d/plugins
2525
key: tflint-v2-${{ hashFiles('.tflint.hcl') }}
2626
restore-keys: |
2727
tflint-v2-
2828
29-
- uses: terraform-linters/setup-tflint@v4
29+
- uses: terraform-linters/setup-tflint@4cb9feea73331a35b422df102992a03a44a3bb33 # v6.2.1
3030

3131
- run: tflint --init
3232
working-directory: example/infra

eslint.config.js renamed to eslint.config.ts

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import antfu from "@antfu/eslint-config"
2+
import e18e from "@e18e/eslint-plugin"
23

34
export default antfu(
45
{
@@ -7,43 +8,50 @@ export default antfu(
78
stylistic: false,
89
jsonc: false,
910
jsx: false,
11+
pnpm: false,
1012
toml: false,
11-
yaml: false,
1213
test: { overrides: { "test/no-import-node-test": "off" } },
1314
typescript: {
1415
tsconfigPath: "tsconfig.json",
16+
ignoresTypeAware: ["copy.ts", "*.config.*"],
17+
1518
overrides: {
1619
"no-console": "off",
17-
"ts/no-use-before-define": "off",
20+
"antfu/no-top-level-await": "off",
21+
"import/consistent-type-specifier-style": ["error", "prefer-top-level"],
22+
"node/prefer-global/process": "off",
1823
"ts/consistent-type-definitions": "off",
19-
"ts/consistent-type-imports": ["error", { fixStyle: "inline-type-imports" }],
24+
"ts/consistent-type-imports": [
25+
"error",
26+
{ fixStyle: "inline-type-imports", disallowTypeAnnotations: false },
27+
],
2028
"ts/no-unsafe-argument": "off",
2129
"ts/no-unsafe-assignment": "off",
22-
"node/prefer-global/process": "off",
23-
"antfu/no-top-level-await": "off",
24-
"import/consistent-type-specifier-style": "off",
30+
"ts/no-use-before-define": "off",
31+
"unicorn/number-literal-case": "off",
32+
"unused-imports/no-unused-vars": "off",
2533

2634
"perfectionist/sort-imports": [
2735
"error",
2836
{
2937
type: "natural",
30-
internalPattern: ["@/.+?", "~/.+?"],
31-
newlinesBetween: "always",
38+
internalPattern: ["^@/", "^~/", "^#[a-zA-Z0-9-]+/"],
39+
newlinesBetween: 1,
3240
groups: [
33-
["builtin", "builtin-type"],
34-
["external", "external-type"],
35-
["internal", "internal-type"],
36-
["parent", "parent-type"],
37-
["sibling", "sibling-type"],
38-
["index", "index-type"],
39-
"object",
41+
"builtin",
42+
"external",
43+
"internal",
44+
"parent",
45+
"sibling",
46+
"index",
4047
"unknown",
4148
],
4249
},
4350
],
4451
},
4552
},
4653
},
54+
e18e.configs!.recommended as never,
4755
{
4856
files: ["example/**"],
4957
rules: {

0 commit comments

Comments
 (0)