Skip to content

Add linter documentation #59

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

Merged
merged 13 commits into from
Jul 15, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add more tools
  • Loading branch information
hasit committed Jul 15, 2024
commit 1d0417278e337cc5db5aba9fcdc335d7854d66a9
75 changes: 75 additions & 0 deletions docs/guides/tools/markdownlint.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
---
title: Markdownlint
sidebar_label: Markdownlint
description: CodeRabbit's guide to Markdownlint.
sidebar_position: 3
---

[Markdownlint](https://github.com/DavidAnson/markdownlint) is a linter for Markdown files.

## Files

Markdownlint will run on files with the following extensions:

- `.md`
- `.markdown`

## Settings

Markdownlint supports the following config files:

- `.markdownlint.jsonc`
- `.markdownlint.json`
- `.markdownlint.yaml`
- `.markdownlint.yml`

CodeRabbit will use the following settings based on the profile selected if no config file is found:

### Chill

```json
{
"default": true,
"line-length": false,
"no-duplicate-heading": {
"siblings_only": true
},
"no-trailing-punctuation": {
"punctuation": ".,;:"
},
"ol-prefix": false,
"list-marker-space": false,
"no-inline-html": false,
"first-line-h1": false,
"no-trailing-spaces": false,
"single-h1": false,
"blank_lines": false,
}
```

### Assertive

```json
{
"default": true,
"line-length": false,
"no-duplicate-heading": {
"siblings_only": true
},
"no-trailing-punctuation": {
"punctuation": ".,;:"
},
"ol-prefix": true,
"list-marker-space": false,
"no-inline-html": true,
"first-line-h1": true,
"no-trailing-spaces": true,
"single-h1": true,
"blank_lines": true,
}

```

## Links

- [Markdownlint Configuration](https://github.com/DavidAnson/markdownlint?tab=readme-ov-file#configuration)
16 changes: 11 additions & 5 deletions docs/guides/tools/ruff.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,16 @@
title: Ruff
sidebar_label: Ruff
description: CodeRabbit's guide to Ruff.
sidebar_position: 1
sidebar_position: 2
---

Ruff is a linter and code formatter for Python.
[Ruff](https://docs.astral.sh/ruff/) is a linter and code formatter for Python.

## Files

Ruff will run on files with the following extensions:

- `.py`

## Settings

Expand All @@ -15,7 +21,7 @@ Ruff supports the following config files:
- `ruff.toml`
- `.ruff.toml`

CodeRabbit will use the following settings if no config file is found:
CodeRabbit will use the following settings based on the profile selected if no config file is found:

### Chill

Expand Down Expand Up @@ -117,6 +123,6 @@ select = [
"**/{test,tests}/**/*.py" = ["S101"]
```

Links:
## Links

- [Ruff](https://docs.astral.sh/ruff/configuration/)
- [Ruff Configuration](https://docs.astral.sh/ruff/configuration/)
37 changes: 37 additions & 0 deletions docs/guides/tools/shellcheck.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
title: ShellCheck
sidebar_label: ShellCheck
description: CodeRabbit's guide to ShellCheck.
sidebar_position: 1
---

[ShellCheck](https://www.shellcheck.net/) is a linter for shell scripts.

## Files

ShellCheck will run on files with the following extensions:

- `.sh`
- `.bash`
- `.ksh`
- `.dash`

## Settings

CodeRabbit will use the following settings based on the profile selected:

### Chill

```shell
--severity=warning
```

### Assertive

```shell
--severity=style
```

## Links

- [ShellCheck Wiki](https://www.shellcheck.net/wiki/)