Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
markdown-list-linter
Advanced tools
Lint markdown lists to warn when list items are not alphabetically ordered
Lints markdown lists and warn when list items are not alphabetically ordered.
This functionality is available to be consumed in three different ways:
⚡ A GitHub Action as part of your CI/CD process
📦 An NPM package that can be consumed in your JavaScript or TypeScript code
💻 A CLI that you can run in your terminal
You can install this package in your JavaScript or Typescript project.
npm install markdown-list-linter
Very simple to use, all results will be container in the returned object.
import { lintMarkdownList } from '../src/markdown-list-linter'
const results = lintMarkdownList('./path/to/markdown/file.md')
console.log(results)
When there are no errors, the returned object should look something like this.
{ 'summary': 'No errors found' }
When there are errors, the returned object should look something like this.
{
'summary': 'Markdown list needs to be sorted',
'errorObject': [
{
'type': 'HEADINGS',
'message': 'Please correct the alphabetical order for these heading items',
'details': [
['C'],
['D', 'A']
],
},
{
'type': 'LIST_ITEMS',
'message': 'Please correct the alphabetical order for these list items',
'details': [
[
`[African Buffalo]('https://www.AfricanBuffalo.com')`,
`[Aardwolf]('https://www.Aardwolf.com')`
],
[
`[Chameleon]('https://www.Chameleon.com')`,
`[Camel]('https://www.Camel.com')`,
`[Cheetah]('https://www.Cheetah.com')`,
`[Canary]('https://www.Canary.com')`
]
],
}
]
}
The array items in the details
object is sections in the list which need to be reordered.
FAQs
Lint markdown lists to warn when list items are not alphabetically ordered
The npm package markdown-list-linter receives a total of 0 weekly downloads. As such, markdown-list-linter popularity was classified as not popular.
We found that markdown-list-linter demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.