Skip to content

Commit

Permalink
Merge pull request #2 from zentered/feat/include-exclude
Browse files Browse the repository at this point in the history
feat: include and exclude paths, add toml support
  • Loading branch information
PatrickHeneise authored Mar 15, 2021
2 parents 860fdc7 + 8627777 commit 70a4bfe
Show file tree
Hide file tree
Showing 16 changed files with 4,550 additions and 191 deletions.
1 change: 1 addition & 0 deletions .github/workflows/seocheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ jobs:
- name: Markdown SEO Check
uses: ./
with:
includes: 'test/pass/*.md'
max_title_length: 70
max_description_length: 150
max_slug_length: 100
Expand Down
12 changes: 7 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,13 @@ Validate markdown files with SEO best practices. Creates a pull request comment
## Inputs
| Name | Requirement | Default | Description |
| ------------------------ | ----------- | ------- | ----------------------------- |
| `max_title_length` | required | 70 | Maximum length of page title |
| `max_description_length` | required | 150 | Maximum length of description |
| `max_slug_length` | required | 100 | Maximum length of slug |
| Name | Requirement | Default | Description |
| ------------------------ | ----------- | -------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
| `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. |
| `excludes` | optional | '' | Glob to exclude files or folders |
| `max_title_length` | required | 70 | Maximum length of page title |
| `max_description_length` | required | 150 | Maximum length of description |
| `max_slug_length` | required | 100 | Maximum length of slug |

## Outputs

Expand Down
8 changes: 8 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@ branding:
icon: check-square
description: 'Check markdown files '
inputs:
includes:
description: Glob to include specific files or folders
required: false
default: '{*.md,*.mdx}'
excludes:
description: Glob to exclude specific files or folders
required: false
default: ''
max_title_length:
description: 'Maximum length for page title'
required: true
Expand Down
Loading

0 comments on commit 70a4bfe

Please sign in to comment.