File tree Expand file tree Collapse file tree 3 files changed +19
-2
lines changed Expand file tree Collapse file tree 3 files changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ since: "v0.4.0"
13
13
14
14
<!-- end auto-generated rule header -->
15
15
16
- > disallow unnecessary Non -capturing group
16
+ > disallow unnecessary non -capturing group
17
17
18
18
## :book : Rule Details
19
19
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ since: "v0.3.0"
13
13
14
14
<!-- end auto-generated rule header -->
15
15
16
- > disallow unnecessary range of characters by using a hyphen
16
+ > disallow unnecessary character ranges
17
17
18
18
## :book : Rule Details
19
19
Original file line number Diff line number Diff line change 150
150
return this
151
151
}
152
152
153
+ public updateHeaderDescription ( ) {
154
+ const { description } = this . rule . meta . docs
155
+
156
+ this . content = this . content . replace (
157
+ // eslint-disable-next-line regexp/no-super-linear-move -- ignore
158
+ / \n + > [ ^ \n ] * \n + # # \s [ ^ \n ] * R u l e D e t a i l s / u,
159
+ `
160
+
161
+ > ${ description . replace ( / \$ / gu, "$$$$" ) }
162
+
163
+ ## :book: Rule Details` ,
164
+ )
165
+
166
+ return this
167
+ }
168
+
153
169
public write ( ) {
154
170
this . content = this . content . replace ( / \r ? \n / gu, "\n" )
155
171
@@ -166,6 +182,7 @@ async function main() {
166
182
await doc . updateFooter ( )
167
183
doc . updateCodeBlocks ( )
168
184
await doc . updateFileIntro ( )
185
+ doc . updateHeaderDescription ( )
169
186
doc . adjustCodeBlocks ( )
170
187
doc . write ( )
171
188
}
You can’t perform that action at this time.
0 commit comments