Skip to content

Commit 6920891

Browse files
committed
feat: update and add pre-release
1 parent c68bc3e commit 6920891

File tree

13 files changed

+903
-862
lines changed

13 files changed

+903
-862
lines changed

.github/ISSUE_TEMPLATE/01-command_bug_report.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ body:
5151
description: List necessary versions here. This includes your package version, runtime version, operating system etc.
5252
placeholder: |
5353
- @nanoforge-dev/schematics 1.0.0 (`npm ls @nanoforge-dev/schematics`)
54-
- Node.js 24.11.0 (`node --version`)
54+
- Node.js 25.x.x (`node --version`)
5555
- TypeScript 5.9.3 (`npm ls typescript` if you use it)
5656
- macOS Ventura 13.3.1
5757
validations:

.github/actions/prepare/action.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: prepare
2+
description: Prepare action
3+
inputs:
4+
node-install:
5+
description: Install node
6+
default: "true"
7+
pnpm-install:
8+
description: Install pnpm depedencies
9+
default: "true"
10+
build:
11+
description: Build packages
12+
default: "true"
13+
runs:
14+
using: composite
15+
steps:
16+
- if: inputs.node-install == 'true'
17+
name: Install Node.js v25
18+
uses: actions/setup-node@v6
19+
with:
20+
node-version: 25
21+
package-manager-cache: false
22+
registry-url: https://registry.npmjs.org
23+
24+
- if: inputs.pnpm-install == 'true'
25+
name: Install dependencies
26+
uses: ./.github/actions/pnpm-install
27+
28+
- if: inputs.build == 'true'
29+
name: Build packages
30+
shell: bash
31+
run: pnpm run build

.github/workflows/pre-release.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Pre-Release
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
version:
7+
description: "New version of the package (leave empty for auto generated version)"
8+
type: string
9+
required: false
10+
dry_run:
11+
description: Perform a dry run?
12+
type: boolean
13+
default: false
14+
15+
permissions:
16+
contents: write
17+
pull-requests: write
18+
19+
jobs:
20+
create-release-pr:
21+
name: Create release pr
22+
runs-on: ubuntu-latest
23+
if: github.repository_owner == 'NanoForge-dev'
24+
steps:
25+
- name: Checkout repository
26+
uses: actions/checkout@v6
27+
with:
28+
fetch-depth: 0
29+
fetch-tags: true
30+
31+
- name: Prepare
32+
uses: ./.github/actions/prepare
33+
34+
- name: Release packages
35+
uses: ./node_modules/@nanoforge-dev/actions/dist/create-release-pr
36+
with:
37+
package: "@nanoforge-dev/schematics"
38+
version: ${{ inputs.version }}
39+
dry: ${{ inputs.dry_run }}
40+
env:
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/release-tag.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Release Tag
2+
3+
on:
4+
pull_request:
5+
types:
6+
- closed
7+
branches:
8+
- main
9+
10+
permissions:
11+
contents: write
12+
13+
jobs:
14+
create-release-tag:
15+
name: Create release tag
16+
runs-on: ubuntu-latest
17+
if: github.repository_owner == 'NanoForge-dev' && github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/')
18+
steps:
19+
- name: Checkout repository
20+
uses: actions/checkout@v6
21+
22+
- name: Prepare
23+
uses: ./.github/actions/prepare
24+
25+
- name: Create release tag
26+
uses: ./node_modules/@nanoforge-dev/actions/dist/create-release-tag
27+
with:
28+
commit: ${{ github.sha }}
29+
branch: ${{ github.head_ref }}
30+
env:
31+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ jobs:
2020
- name: Checkout repository
2121
uses: actions/checkout@v6
2222

23-
- name: Install Node.js v24
23+
- name: Install Node.js v25
2424
uses: actions/setup-node@v6
2525
with:
26-
node-version: 24
26+
node-version: 25
2727
package-manager-cache: false
2828
registry-url: https://registry.npmjs.org/
2929

.github/workflows/tests.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Tests
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
push:
8+
branches:
9+
- main
10+
workflow_dispatch:
11+
12+
jobs:
13+
tests:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout repository
17+
uses: actions/checkout@v6
18+
19+
- name: Prepare
20+
uses: ./.github/actions/prepare
21+
22+
- name: Run linter
23+
run: pnpm lint

.husky/pre-commit

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
11
pnpm --no-install lint-staged
2-
pnpm format

.nvmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
24.11.1
1+
25

eslint.config.js

Lines changed: 2 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,3 @@
1-
import pluginJs from "@eslint/js";
2-
import eslintConfigPrettier from "eslint-config-prettier";
3-
import globals from "globals";
4-
import tseslint from "typescript-eslint";
1+
import eslintConfig from "@nanoforge-dev/utils-eslint-config";
52

6-
export default [
7-
{ files: ["src/**/*.{ts}"] },
8-
{ languageOptions: { globals: globals.node } },
9-
10-
pluginJs.configs.recommended,
11-
...tseslint.configs.recommended,
12-
...tseslint.configs.strict,
13-
eslintConfigPrettier,
14-
{ ignores: ["**/*.js", "**/*.d.ts", "src/libs/**/files/**/*"] },
15-
{
16-
rules: {
17-
"@typescript-eslint/consistent-type-imports": [
18-
"error",
19-
{
20-
disallowTypeAnnotations: true,
21-
fixStyle: "inline-type-imports",
22-
prefer: "type-imports",
23-
},
24-
],
25-
"@typescript-eslint/no-extraneous-class": "off",
26-
"@typescript-eslint/no-empty-object-type": "off",
27-
"@typescript-eslint/no-explicit-any": "off",
28-
"@typescript-eslint/ban-ts-comment": "off",
29-
"@typescript-eslint/member-ordering": [
30-
"error",
31-
{
32-
default: [
33-
"static-field",
34-
"field",
35-
"public-static-method",
36-
"constructor",
37-
"method",
38-
"protected-method",
39-
"private-method",
40-
],
41-
},
42-
],
43-
},
44-
},
45-
];
3+
export default [...eslintConfig, { ignores: ["src/libs/**/files/**/*"] }];

package.json

Lines changed: 21 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -58,43 +58,37 @@
5858
"prepare": "husky"
5959
},
6060
"dependencies": {
61-
"@angular-devkit/core": "^21.0.0",
62-
"@angular-devkit/schematics": "^21.0.0"
61+
"@angular-devkit/core": "catalog:schematics",
62+
"@angular-devkit/schematics": "catalog:schematics"
6363
},
6464
"devDependencies": {
65-
"@commitlint/cli": "^20.1.0",
66-
"@commitlint/config-conventional": "^20.0.0",
67-
"@eslint/js": "^9.39.0",
68-
"@favware/cliff-jumper": "^6.0.0",
69-
"@nanoforge-dev/actions": "^1.0.2",
70-
"@trivago/prettier-plugin-sort-imports": "^5.2.2",
71-
"@types/node": "^24.10.1",
72-
"@typescript-eslint/eslint-plugin": "^8.46.2",
73-
"@typescript-eslint/parser": "^8.46.2",
74-
"cpx2": "^8.0.0",
75-
"eslint": "^9.39.0",
76-
"eslint-config-prettier": "^10.1.8",
77-
"eslint-formatter-pretty": "^7.0.0",
78-
"eslint-plugin-prettier": "^5.5.4",
79-
"globals": "^16.5.0",
80-
"husky": "^9.1.7",
81-
"lint-staged": "^16.2.6",
82-
"prettier": "^3.6.2",
83-
"tsup": "^8.5.1",
84-
"typescript": "^5.9.3",
85-
"typescript-eslint": "^8.46.2"
65+
"@commitlint/cli": "catalog:ci",
66+
"@commitlint/config-conventional": "catalog:ci",
67+
"@favware/cliff-jumper": "catalog:ci",
68+
"@nanoforge-dev/actions": "catalog:ci",
69+
"@nanoforge-dev/utils-eslint-config": "catalog:lint",
70+
"@nanoforge-dev/utils-prettier-config": "catalog:lint",
71+
"@trivago/prettier-plugin-sort-imports": "catalog:lint",
72+
"@types/node": "catalog:core",
73+
"cpx2": "catalog:build",
74+
"eslint": "catalog:lint",
75+
"husky": "catalog:ci",
76+
"lint-staged": "catalog:ci",
77+
"prettier": "catalog:lint",
78+
"tsup": "catalog:build",
79+
"typescript": "catalog:build"
8680
},
87-
"packageManager": "pnpm@10.24.0",
81+
"packageManager": "pnpm@10.28.1",
8882
"engines": {
89-
"node": "24.11.1"
83+
"node": "25"
9084
},
9185
"publishConfig": {
9286
"access": "public"
9387
},
9488
"schematics": "./dist/collection.json",
9589
"lint-staged": {
96-
"**/*.ts": [
97-
"prettier --write"
90+
"**": [
91+
"prettier --ignore-unknown --write"
9892
],
9993
"src/**/*.ts": [
10094
"eslint --fix"

0 commit comments

Comments
 (0)