Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ydah/mdformat-action
Github Action for linting markdown files using mdformat
https://github.com/ydah/mdformat-action
actions formatting github-actions hacktoberfest markdown
Last synced: 30 days ago
JSON representation
Github Action for linting markdown files using mdformat
- Host: GitHub
- URL: https://github.com/ydah/mdformat-action
- Owner: ydah
- License: mit
- Created: 2022-08-30T11:22:02.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-22T04:55:23.000Z (10 months ago)
- Last Synced: 2024-10-06T04:31:27.936Z (about 1 month ago)
- Topics: actions, formatting, github-actions, hacktoberfest, markdown
- Language: Shell
- Homepage:
- Size: 15.6 KB
- Stars: 3
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# mdformat-action
[Custom action](https://docs.github.com/en//actions/creating-actions/about-custom-actions) for linting markdown files using [mdformat](https://github.com/executablebooks/mdformat).
## Usage
Add the following workflow file to run the action:
```yaml
# .github/workflows/mdformat.yml
name: Mdformat Action
on:
- pull_request
jobs:
mdformat:
name: Mdformat Action
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Mdformat Action
uses: ydah/mdformat-action@main
with:
number: true
env:
GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
```## Inputs
### `file_or_dir`
- File or Directory to do mdformat on.
- default: `.`
- optional### `number`
- Apply consecutive numbering to ordered lists.
- default: `false`
- optional### `wrap`
- Paragraph word wrap mode.
- keep
- no
- INTEGER
- default: `keep`
- optional### `end_of_line`
- Output file line ending mode.
- lf
- crlf
- keep
- default: `lf`
- optional### `auto_correct`
- Adding commit by autocorrect for mdformat.
- default: `false`
- optional