Skip to content

Commit a66e492

Browse files
authored
Merge pull request #383 from MH4GF/maintenance
maintenance
2 parents 88b7c46 + 5457ddb commit a66e492

File tree

8 files changed

+348
-30
lines changed

8 files changed

+348
-30
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ on:
55
- main
66

77
jobs:
8-
build:
8+
ci:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
11+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
1212
- uses: MH4GF/shared-config/.github/composite-actions/setup-pnpm@main
1313
- run: pnpm run all

.github/workflows/keep-main-version-branch.yml

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

.github/workflows/tagpr.yml

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,26 @@ jobs:
88
steps:
99
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
1010
- uses: Songmu/tagpr@3dca11e7c0d68637ee212ddd35acc3d30a7403a4 # v1.5.0
11+
id: run-tagpr
1112
env:
12-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
13+
GITHUB_TOKEN: ${{ secrets.MH4GF_PAT }}
14+
outputs:
15+
tagpr-tag: ${{ steps.run-tagpr.outputs.tag }}
16+
17+
bump_major_branch:
18+
if: needs.tagpr.outputs.tagpr-tag != ''
19+
needs: tagpr
20+
runs-on: ubuntu-latest
21+
timeout-minutes: 5
22+
permissions:
23+
contents: write
24+
steps:
25+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
26+
- name: Git config
27+
run: |
28+
git config user.name "github-actions[bot]"
29+
git config user.email "github-actions[bot]@users.noreply.github.com"
30+
- name: Get major version
31+
run: echo "MAJOR_VERSION=$(echo ${{ needs.tagpr.outputs.tagpr-tag }} | cut -d '.' -f 1)" >> "$GITHUB_ENV"
32+
- name: Push new tag
33+
run: git push --force origin "HEAD:refs/heads/${MAJOR_VERSION}"

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
pull-requests: write
1212
runs-on: ubuntu-latest
1313
steps:
14-
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
14+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
1515
- uses: ./
1616
with:
1717
package-manager: pnpm

.github/workflows/update-dist.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717

1818
steps:
1919
- name: Checkout code
20-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
20+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2121
with:
2222
ref: ${{ github.event.pull_request.head.ref }}
2323
token: ${{ secrets.MH4GF_PAT }}

knip.jsonc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"entry": ["src/main.ts", ".dependency-cruiser.js"],
3+
"ignore": ["dist/**", "test/**"]
4+
}

package.json

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,19 @@
99
"url": "git+https://github.com/MH4GF/dependency-cruiser-report-action.git"
1010
},
1111
"license": "MIT",
12-
"author": "",
12+
"author": {
13+
"name": "Hirotaka Miyagi",
14+
"email": "[email protected]"
15+
},
1316
"main": "lib/main.js",
1417
"scripts": {
15-
"all": "npm run build && npm run lint && npm test",
16-
"build": "tsc",
17-
"coverage": "vitest run --coverage",
18-
"format": "biome check --apply-unsafe .",
19-
"lint": "pnpm run lint:biome & pnpm run lint:depcruise",
18+
"all": "pnpm run lint && pnpm run test",
19+
"fmt": "biome check --write --unsafe .",
20+
"lint": "pnpm run '/^lint:.*/'",
2021
"lint:biome": "biome ci .",
2122
"lint:depcruise": "depcruise src --config",
23+
"lint:knip": "knip",
24+
"lint:tsc": "tsc --noEmit",
2225
"package": "ncc build src/main.ts --source-map --license licenses.txt",
2326
"test": "vitest"
2427
},
@@ -34,7 +37,7 @@
3437
"@types/node": "22.10.5",
3538
"@vercel/ncc": "0.38.3",
3639
"dependency-cruiser": "16.8.0",
37-
"js-yaml": "4.1.0",
40+
"knip": "5.41.1",
3841
"typescript": "5.7.2",
3942
"vitest": "2.1.8"
4043
},

0 commit comments

Comments
 (0)