@markuplint/create-rule 5.0.0-alpha.0 → 5.0.0-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,14 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [5.0.0-alpha.2](https://github.com/markuplint/markuplint/compare/v5.0.0-alpha.1...v5.0.0-alpha.2) (2026-02-23)
7
+
8
+ **Note:** Version bump only for package @markuplint/create-rule
9
+
10
+ # [5.0.0-alpha.1](https://github.com/markuplint/markuplint/compare/v5.0.0-alpha.0...v5.0.0-alpha.1) (2026-02-22)
11
+
12
+ **Note:** Version bump only for package @markuplint/create-rule
13
+
6
14
  # [5.0.0-alpha.0](https://github.com/markuplint/markuplint/compare/v4.14.1...v5.0.0-alpha.0) (2026-02-20)
7
15
 
8
16
  ### Bug Fixes
@@ -123,9 +123,9 @@ i18n を多用するルール:
123
123
 
124
124
  `packages/@markuplint/rules/src/` ディレクトリを参照して、作成しようとしているルールに類似した実装を探してください。
125
125
 
126
- ## fix 関数について
126
+ ## fix コールバックについて
127
127
 
128
- `fix` 関数は `RuleSeed` のオプションプロパティで、違反の自動修正を可能にします。しかし、多くの既存ルールでは `fix` の実装が不完全または未実装です。新しいルールを作成する際は、まず `verify` 関数に注力してください。`fix` は自動修正の動作が明確で単純な場合にのみ追加してください。
128
+ 自動修正は `verify()` 内の個々の `report()` 呼び出しにインライン `fix` コールバックとして提供され、独立した `RuleSeed` メソッドではありません。コールバックは `TextEdit` オブジェクトを構築するための `IRuleFixer` ヘルパーを受け取ります。新しいルールを作成する際は、まず `verify` 関数に注力してください。`fix` コールバックは自動修正の動作が明確で単純な場合にのみ `report()` に追加してください。
129
129
 
130
130
  ## コマンドリファレンス
131
131
 
@@ -123,9 +123,9 @@ Rules with rich i18n usage:
123
123
 
124
124
  Browse the `packages/@markuplint/rules/src/` directory to find rules similar to what you are building.
125
125
 
126
- ## About the `fix` Function
126
+ ## About the `fix` Callback
127
127
 
128
- The `fix` function is an optional property of `RuleSeed` that enables auto-fixing violations. However, many existing rules have incomplete or missing `fix` implementations. When creating a new rule, focus on the `verify` function first. Add `fix` only if the auto-fix behavior is straightforward and well-defined.
128
+ Auto-fix is provided as an inline `fix` callback on individual `report()` calls within `verify()`, not as a separate `RuleSeed` method. The callback receives an `IRuleFixer` helper for building `TextEdit` objects. When creating a new rule, focus on the `verify` function first. Add a `fix` callback to `report()` only if the auto-fix behavior is straightforward and well-defined.
129
129
 
130
130
  ## Command Reference
131
131
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@markuplint/create-rule",
3
- "version": "5.0.0-alpha.0",
3
+ "version": "5.0.0-alpha.2",
4
4
  "description": "Rule generator for markuplint",
5
5
  "repository": "git@github.com:markuplint/markuplint.git",
6
6
  "author": "Yusuke Hirao <yusukehirao@me.com>",
@@ -25,8 +25,8 @@
25
25
  "clean": "tsc --build --clean tsconfig.build.json"
26
26
  },
27
27
  "dependencies": {
28
- "@markuplint/cli-utils": "5.0.0-alpha.0",
29
- "@markuplint/ml-core": "5.0.0-alpha.0",
28
+ "@markuplint/cli-utils": "5.0.0-alpha.2",
29
+ "@markuplint/ml-core": "5.0.0-alpha.2",
30
30
  "glob": "13.0.6",
31
31
  "prettier": "3.8.1",
32
32
  "typescript": "5.9.3"
@@ -35,5 +35,5 @@
35
35
  "@types/fs-extra": "11.0.4",
36
36
  "fs-extra": "11.3.3"
37
37
  },
38
- "gitHead": "13dcfc84ec83d87360c720e253383b60767e1b56"
38
+ "gitHead": "31ccf1e81443ea3f93597d287595211f1823ddcf"
39
39
  }