-
Notifications
You must be signed in to change notification settings - Fork 47
Add documentation style guide and tool configs #5320
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
383802b
ad0c86d
4f26cbc
7db57b7
36cb1b6
4253214
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"gitignore": true, | ||
"globs": ["**/*.md"], | ||
"ignores": [ | ||
"node_modules/", | ||
".docusaurus", | ||
"build/", | ||
"docs/ref/cli/", | ||
"docs/ref/proto.md", | ||
], | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
{ | ||
"code-block-style": { | ||
"style": "fenced" | ||
}, | ||
"code-fence-style": { | ||
"style": "backtick" | ||
}, | ||
"emphasis-style": { | ||
"style": "underscore" | ||
}, | ||
"heading-style": { | ||
"style": "atx" | ||
}, | ||
"hr-style": { | ||
"style": "---" | ||
}, | ||
"line-length": { | ||
"code_blocks": false, | ||
"line_length": 80, | ||
"tables": false | ||
}, | ||
"no-bare-urls": false, | ||
"no-duplicate-heading": false, | ||
danbarr marked this conversation as resolved.
Show resolved
Hide resolved
|
||
"proper-names": { | ||
"code_blocks": false, | ||
"names": ["GitHub", "GitLab", "Bitbucket"] | ||
}, | ||
"strong-style": { | ||
"style": "asterisk" | ||
}, | ||
"table-pipe-style": { | ||
"style": "leading_and_trailing" | ||
}, | ||
"ul-style": { | ||
"style": "dash" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I always use There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I used to also; the rationale I drew this from was that it's easier to read when you do things like this: * **A bold bullet**
vs.
- **A bold b
8000
ullet** But frankly, this is a nit - if Markdownlint also support a * Item 1
+ Item 2
- Item 3
+ Item 4
* Item 4
+ Item 5 |
||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
node_modules/ | ||
.docusaurus/ | ||
build/ | ||
|
||
# Auto-generated files | ||
docs/ref/cli/*.md | ||
docs/ref/proto.md |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"jsxSingleQuote": true, | ||
"printWidth": 80, | ||
"proseWrap": "always", | ||
"singleQuote": true, | ||
"tabWidth": 2, | ||
"trailingComma": "es5", | ||
"useTabs": false | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,66 @@ | ||
# Docs for Minder | ||
# Minder documentation | ||
|
||
This directory contains the user documentation for Minder, hosted at | ||
<https://mindersec.github.io>. | ||
|
||
The docs are built with [Docusaurus](<[https://](https://docusaurus.io/)>), an | ||
open source static website generator optimized for documentation use cases. | ||
|
||
## Contributing to docs | ||
|
||
We welcome community contributions to the Minder documentation - if you find | ||
something missing, wrong, or unclear, please let us know via an issue or open a | ||
PR! | ||
|
||
Please review the [style guide](./STYLE-GUIDE.md) for help with voice, tone, and | ||
formatting. | ||
|
||
## Building the docs locally | ||
|
||
Start from the top level directory of the repository. | ||
Start from the top level directory of the `minder` repository and generate the | ||
CLI docs: | ||
|
||
Generate the CLI docs | ||
``` | ||
```bash | ||
make cli-docs | ||
``` | ||
|
||
Build the docs | ||
``` | ||
cd docs | ||
``` | ||
Run a preview server: | ||
|
||
```bash | ||
npm run start | ||
``` | ||
danbarr marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
Your browser should automatically open to <http://localhost:3000> | ||
|
||
Build the docs: | ||
|
||
```bash | ||
cd docs | ||
npm run build | ||
``` | ||
|
||
Serve the docs | ||
``` | ||
|
||
```bash | ||
npm run serve -- --port 3001 | ||
``` | ||
|
||
Visit http://localhost:3001/ to view the docs. | ||
|
||
## Formatting | ||
|
||
Before you submit a PR, please check for formatting and linting issues: | ||
|
||
```bash | ||
npm run prettier | ||
npm run markdownlint | ||
npm run eslint | ||
``` | ||
|
||
To automatically fix issues: | ||
|
||
```bash | ||
npm run prettier:fix | ||
npm run markdownlint:fix | ||
npm run eslint:fix | ||
``` |
Uh oh!
There was an error while loading. Please reload this page.