Skip to content

Commit 70a4bfe

Browse files
Merge pull request #2 from zentered/feat/include-exclude
feat: include and exclude paths, add toml support
2 parents 860fdc7 + 8627777 commit 70a4bfe

16 files changed

+4550
-191
lines changed

.github/workflows/seocheck.yml

+1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ jobs:
1313
- name: Markdown SEO Check
1414
uses: ./
1515
with:
16+
includes: 'test/pass/*.md'
1617
max_title_length: 70
1718
max_description_length: 150
1819
max_slug_length: 100

README.md

+7-5
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,13 @@ Validate markdown files with SEO best practices. Creates a pull request comment
3535
3636
## Inputs
3737
38-
| Name | Requirement | Default | Description |
39-
| ------------------------ | ----------- | ------- | ----------------------------- |
40-
| `max_title_length` | required | 70 | Maximum length of page title |
41-
| `max_description_length` | required | 150 | Maximum length of description |
42-
| `max_slug_length` | required | 100 | Maximum length of slug |
38+
| Name | Requirement | Default | Description |
39+
| ------------------------ | ----------- | -------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
40+
| `includes` | optional | `{*.md,*.mdx}` | Glob to include specific files or folders. See [glob-to-regexp usage](https://www.npmjs.com/package/glob-to-regexp#usage) for examples. |
41+
| `excludes` | optional | '' | Glob to exclude files or folders |
42+
| `max_title_length` | required | 70 | Maximum length of page title |
43+
| `max_description_length` | required | 150 | Maximum length of description |
44+
| `max_slug_length` | required | 100 | Maximum length of slug |
4345

4446
## Outputs
4547

action.yml

+8
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,14 @@ branding:
33
icon: check-square
44
description: 'Check markdown files '
55
inputs:
6+
includes:
7+
description: Glob to include specific files or folders
8+
required: false
9+
default: '{*.md,*.mdx}'
10+
excludes:
11+
description: Glob to exclude specific files or folders
12+
required: false
13+
default: ''
614
max_title_length:
715
description: 'Maximum length for page title'
816
required: true

0 commit comments

Comments
 (0)