mirror of
https://github.com/kristoferssolo/runner.nvim.git
synced 2025-10-21 19:50:34 +00:00
Add more docs for contributing (#9)
* Make the pre-commit hook use the stylua binary installed on the system * Add docs for contributing
This commit is contained in:
parent
7a098964c6
commit
4b96ddcfbe
@ -2,4 +2,4 @@ repos:
|
|||||||
- repo: https://github.com/JohnnyMorganz/StyLua
|
- repo: https://github.com/JohnnyMorganz/StyLua
|
||||||
rev: v0.17.1
|
rev: v0.17.1
|
||||||
hooks:
|
hooks:
|
||||||
- id: stylua-github
|
- id: stylua-system
|
||||||
|
|||||||
23
README.md
23
README.md
@ -164,6 +164,27 @@ A customizable Neovim plugin to run code inside the editor
|
|||||||
|
|
||||||
## Contribution
|
## Contribution
|
||||||
|
|
||||||
If you find that some handlers for a specific language are missing, feel free to open a pull request by adding them in the [lua/runner/handlers/init.lua](lua/runner/handlers/init.lua) file.
|
This project uses [StyLua](https://github.com/JohnnyMorganz/StyLua) for enforcing code style, and has a [pre-commit](https://pre-commit.com/) hook setup for running it automatically. `runner.nvim` also has a Github Action that runs the linter on every Pull request. If a check doesn't pass on a specific Pull request, please lint the code and commit it again.
|
||||||
|
|
||||||
|
For running them locally, you have to have them installed on your system:
|
||||||
|
- [StyLua Installation](https://github.com/JohnnyMorganz/StyLua#installation)
|
||||||
|
- [pre-commit Installation](https://pre-commit.com/#install)
|
||||||
|
|
||||||
|
#### Some useful commands:
|
||||||
|
|
||||||
|
- Install the pre-commit hook
|
||||||
|
```bash
|
||||||
|
pre-commit install
|
||||||
|
```
|
||||||
|
|
||||||
|
- Check for StyLua errors
|
||||||
|
```bash
|
||||||
|
stylua --check lua/
|
||||||
|
```
|
||||||
|
|
||||||
|
- Fix StyLua errors
|
||||||
|
```bash
|
||||||
|
stylua lua/
|
||||||
|
```
|
||||||
|
|
||||||
Licensed under the [MIT license](./LICENSE).
|
Licensed under the [MIT license](./LICENSE).
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user