File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -93,14 +93,14 @@ There are a few things to keep in mind when writing your action code:
93
93
In ` main.ts ` , you will see that the action is run in an ` async ` function.
94
94
95
95
``` javascript
96
- import * as core from ' @actions/core'
96
+ import * as core from ' @actions/core' ;
97
97
// ...
98
98
99
99
async function run () {
100
100
try {
101
101
// ...
102
102
} catch (error) {
103
- core .setFailed (error .message )
103
+ core .setFailed (error .message );
104
104
}
105
105
}
106
106
```
Original file line number Diff line number Diff line change @@ -11,4 +11,4 @@ export const setFailed = jest.fn<typeof core.setFailed>();
11
11
export const warning = jest . fn < typeof core . warning > ( ) ;
12
12
export const startGroup = jest . fn < typeof core . startGroup > ( ) ;
13
13
export const endGroup = jest . fn < typeof core . endGroup > ( ) ;
14
- export const isDebug = jest . fn < typeof core . isDebug > ( ) ;
14
+ export const isDebug = jest . fn < typeof core . isDebug > ( ) ;
Original file line number Diff line number Diff line change @@ -29,7 +29,9 @@ export const runAction = async (input: Input): Promise<void> => {
29
29
let filesToCheck : string [ ] = [ ] ;
30
30
core . startGroup ( `Loading files to check.` ) ;
31
31
if ( input . files ) {
32
- filesToCheck = input . files . split ( ' ' ) . map ( ( file ) => file . startsWith ( '/' ) ? file : `/${ file } ` ) ;
32
+ filesToCheck = input . files
33
+ . split ( ' ' )
34
+ . map ( ( file ) => ( file . startsWith ( '/' ) ? file : `/${ file } ` ) ) ;
33
35
} else {
34
36
filesToCheck = await ( await glob . create ( '*' ) ) . glob ( ) ;
35
37
if ( input [ 'include-gitignore' ] === true ) {
You can’t perform that action at this time.
0 commit comments