Skip to content

Commit 72d871b

Browse files
Merge pull request #88 from bpkroth/master
Fix find command quoting issues for multiple folders.
2 parents 7481451 + 78e8afa commit 72d871b

File tree

4 files changed

+23
-2
lines changed

4 files changed

+23
-2
lines changed

.github/workflows/push.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,15 @@ jobs:
99
uses: ./
1010
with:
1111
check-modified-files-only: 'yes'
12+
markdown-link-check-folders:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@master
16+
- name: markdown-link-check
17+
uses: ./
18+
with:
19+
# Add a test to restrict the test to just dir4 and dir5.
20+
folder-path: './md/dir4, ./md/dir5'
1221
shellcheck:
1322
runs-on: [ubuntu-latest]
1423
steps:

entrypoint.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,9 +182,9 @@ if [ "$CHECK_MODIFIED_FILES" = "yes" ]; then
182182
else
183183

184184
if [ "$5" -ne -1 ]; then
185-
FIND_CALL=('find' "${FOLDERS}" '-name' '*'"${FILE_EXTENSION}" '-not' '-path' './node_modules/*' '-maxdepth' "${MAX_DEPTH}" '-exec' 'markdown-link-check' '{}')
185+
FIND_CALL=('find' ${FOLDERS} '-name' '*'"${FILE_EXTENSION}" '-not' '-path' './node_modules/*' '-maxdepth' "${MAX_DEPTH}" '-exec' 'markdown-link-check' '{}')
186186
else
187-
FIND_CALL=('find' "${FOLDERS}" '-name' '*'"${FILE_EXTENSION}" '-not' '-path' './node_modules/*' '-exec' 'markdown-link-check' '{}')
187+
FIND_CALL=('find' ${FOLDERS} '-name' '*'"${FILE_EXTENSION}" '-not' '-path' './node_modules/*' '-exec' 'markdown-link-check' '{}')
188188
fi
189189

190190
add_options

md/dir4/ok4.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Ok4
2+
3+
## Test
4+
5+
Go to [Ok5](../dir5/ok5.md#test)
6+

md/dir5/ok5.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Ok5
2+
3+
## Test
4+
5+
Go to [Ok4](../dir4/ok4.md#test)
6+

0 commit comments

Comments
 (0)