File tree 3 files changed +11
-11
lines changed
3 files changed +11
-11
lines changed Original file line number Diff line number Diff line change 1
- * text =auto
2
- * .js text eol =lf
1
+ * text =auto eol =lf
3
2
* .ai binary
Original file line number Diff line number Diff line change 1
1
language : node_js
2
2
node_js :
3
+ - ' 10'
3
4
- ' 8'
4
5
- ' 6'
Original file line number Diff line number Diff line change @@ -6,15 +6,15 @@ const toVfile = require('to-vfile');
6
6
const vfileReporterPretty = require ( 'vfile-reporter-pretty' ) ;
7
7
const config = require ( './config' ) ;
8
8
9
- const m = opts => {
10
- opts = Object . assign ( {
9
+ const m = options => {
10
+ options = Object . assign ( {
11
11
filename : 'readme.md'
12
- } , opts ) ;
12
+ } , options ) ;
13
13
14
- const readmeFile = globby . sync ( opts . filename , { nocase : true } ) [ 0 ] ;
14
+ const readmeFile = globby . sync ( options . filename , { nocase : true } ) [ 0 ] ;
15
15
16
16
if ( ! readmeFile ) {
17
- return Promise . reject ( new Error ( `Couldn't find the file ${ opts . filename } ` ) ) ;
17
+ return Promise . reject ( new Error ( `Couldn't find the file ${ options . filename } ` ) ) ;
18
18
}
19
19
20
20
const run = remark ( ) . use ( config ) . process ;
@@ -23,16 +23,16 @@ const m = opts => {
23
23
return pify ( run ) ( file ) ;
24
24
} ;
25
25
26
- m . report = opts => m ( opts ) . then ( file => {
26
+ m . report = options => m ( options ) . then ( file => {
27
27
const { messages} = file ;
28
28
29
29
if ( messages . length === 0 ) {
30
30
return ;
31
31
}
32
32
33
- messages . forEach ( x => {
34
- x . fatal = true ; // eslint-ignore-line TODO: because of https://github.com/wooorm/remark-lint/issues/65
35
- } ) ;
33
+ for ( const message of messages ) {
34
+ message . fatal = true ; // TODO: because of https://github.com/wooorm/remark-lint/issues/65
35
+ }
36
36
37
37
process . exitCode = 1 ;
38
38
You can’t perform that action at this time.
0 commit comments