File tree Expand file tree Collapse file tree 3 files changed +14
-7
lines changed Expand file tree Collapse file tree 3 files changed +14
-7
lines changed Original file line number Diff line number Diff line change @@ -11,12 +11,13 @@ Add a step like this to your workflow:
11
11
12
12
``` yaml
13
13
- name : Commit changes # This is the step name that will be displayed in your runs
14
- uses : EndBug/add-and-commit@latest # You can change this to use a specific version
14
+ uses : EndBug/add-and-commit@v2.0.0 # You can change this to use a specific version
15
15
with : # See more info about inputs below
16
16
author_name : Your Name
17
17
18
18
message : " Your commit message"
19
- path : ./*.js
19
+ path : " ."
20
+ pattern : " *.js"
20
21
env :
21
22
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }} # Leave this line unchanged
22
23
` ` `
@@ -27,6 +28,7 @@ Add a step like this to your workflow:
27
28
- `author_email` : the email of the user that will be displayed as the author of the commit
28
29
- `message` : the message for the commit
29
30
- `path` : the path(s) to stage files from
31
+ - `pattern` : the pattern that matches file names
30
32
31
33
# ## Environment variables:
32
34
@@ -61,12 +63,13 @@ jobs:
61
63
run: eslint "src/**" --fix
62
64
63
65
- name: Commit changes
64
- uses: EndBug/add-and-commit@latest
66
+ uses: EndBug/add-and-commit@v2.0.0
65
67
with:
66
68
author_name: Your Name
67
69
68
70
message: "Your commit message"
69
- path: ./*.js
71
+ path: "."
72
+ pattern: "*.js"
70
73
env:
71
74
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
72
75
` ` `
Original file line number Diff line number Diff line change @@ -17,8 +17,12 @@ inputs:
17
17
path :
18
18
description : ' The path to stage files from'
19
19
required : true
20
- default : ' ./**/*.*'
21
-
20
+ default : ' .'
21
+ pattern :
22
+ description : ' The pattern that mathces file names'
23
+ required : false
24
+ default : " *.*"
25
+
22
26
runs :
23
27
using : ' docker'
24
28
image : ' Dockerfile'
Original file line number Diff line number Diff line change 19
19
}
20
20
21
21
add () {
22
- find $INPUT_PATH -name " *.* " | while read x; do git add $x ; done
22
+ find $INPUT_PATH -name $INPUT_PATTERN | while read x; do git add $x ; done
23
23
}
24
24
25
25
# This is needed to make the check work for untracked files
You can’t perform that action at this time.
0 commit comments