Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/voodoocreation/md-stats
A tool to report on statistics for Markdown file content within a folder (recursively).
https://github.com/voodoocreation/md-stats
cli command command-line count docs documentation markdown node report script scripts statistics stats word word-count wordcount
Last synced: 18 days ago
JSON representation
A tool to report on statistics for Markdown file content within a folder (recursively).
- Host: GitHub
- URL: https://github.com/voodoocreation/md-stats
- Owner: voodoocreation
- Created: 2020-07-03T03:00:41.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2023-07-14T20:34:35.000Z (over 1 year ago)
- Last Synced: 2024-08-09T10:53:56.973Z (6 months ago)
- Topics: cli, command, command-line, count, docs, documentation, markdown, node, report, script, scripts, statistics, stats, word, word-count, wordcount
- Language: JavaScript
- Homepage:
- Size: 22.5 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Markdown Stats
==============A simple tool to report on statistics of Markdown file content within the given directory (recursively).
Useful for reporting how much documentation exists within a project.
Available stats are:
- Markdown file count
- character count
- word countUsage
-----### CLI
If the directory is omitted, it will run for the current directory.If the `--verbose` flag is present, it will also display stats on a per-file basis.
#### Example
```shell script
npx md-stats ./path/to/files --verbose
```### Node.js
The exported function can also be used in a Node.js environment, which will return the raw data.#### Example
```javascript
const getMarkdownStats = require("md-stats");const stats = await getMarkdownStats("./path/to/files");
```The data returned is in the following format:
```
{
characters: number,
words: number,
files: [
{
name: string,
characters: number,
words: number
}
]
}
```