| 1 |
# Contributing to lualine.nvim |
| 2 |
|
| 3 |
Thanks for considering to contribute. |
| 4 |
|
| 5 |
### Getting started |
| 6 |
|
| 7 |
If you're not sure where to help? You can try these: |
| 8 |
|
| 9 |
- You can look at the currently open [issues](https://github.com/nvim-lualine/lualine.nvim/issues) |
| 10 |
to see if some bug needs fixing or for cool feature ideas.<br> |
| 11 |
You should also look at currently open PRs ([Pull requests](https://github.com/nvim-lualine/lualine.nvim/pulls)) to see if some abandoned PR interests you.<br> |
| 12 |
*We could really use some help with tests & docs they are currently lacking :)* |
| 13 |
- You can add an exciting new component, extension or theme. |
| 14 |
Note: Currently we aren't adding regular colorscheme based themes. |
| 15 |
We think they make more sense with colorschemes as they tend not to get |
| 16 |
updated once added here. But if you have some unique themes idea like [auto](https://github.com/nvim-lualine/lualine.nvim/blob/master/THEMES.md#auto) or [pywal](https://github.com/nvim-lualine/lualine.nvim/blob/master/THEMES.md#pywal) feel free to open an PR or issue. |
| 17 |
- Feel free to open issues or unfinished PRs for help. |
| 18 |
I'd actually recommend you to open an issue first for bigger PRs to discuss |
| 19 |
the feature with a maintainer beforehand. That way you can know if the |
| 20 |
feature is likely to be accepted or not before you get started. |
| 21 |
You'll get recommendation and help with implementation specially if you show |
| 22 |
willingness to implement it yourself. |
| 23 |
- Do add tests and docs for your changes. |
| 24 |
|
| 25 |
Good luck! |
| 26 |
|
| 27 |
### Developer tools |
| 28 |
|
| 29 |
*Let's introduce you to the tools we use.* |
| 30 |
|
| 31 |
- Your PR needs to pass tests & linter. We lint our codebase with [luacheck](https://github.com/mpeterv/luacheck) |
| 32 |
and run tests with [plenary-test][plenary.nvim] these will be run on CI. If you want you can run tests & linter |
| 33 |
locally with `make test` & `make lint` respectively. Or `make check` to run both linter & tests. For running |
| 34 |
tests you'll have to make sure lualine.nvim, [plenary.nvim][plenary.nvim] and |
| 35 |
[nvim-web-devicons](https://github.com/nvim-tree/nvim-web-devicons) are in same directory. |
| 36 |
- Lua codebase gets formatted with [stylua](https://github.com/JohnnyMorganz/StyLua) in CI. |
| 37 |
So you can ignore formatting. But if you want to submit formatted |
| 38 |
PR you can run formatter locally with `make format`. |
| 39 |
- VimDocs are auto generated with [panvimdoc](https://github.com/kdheepak/panvimdoc) from README.md. |
| 40 |
So don't make changes to doc/lualine.txt . Instead add your docs to README or Wiki. |
| 41 |
The docgen in ran by CI too. If you want to run it locally you can do so |
| 42 |
with `make docgen`. Note: you'll need to have [pandoc](https://github.com/jgm/pandoc) installed. |
| 43 |
- `make precommit_check` can come quite handy it'll run all the above mentioned tools |
| 44 |
- You can check our test coverage with `make testcov`. |
| 45 |
You'll need to have [luacov](https://github.com/keplerproject/luacov) |
| 46 |
& [luacov-console](https://github.com/spacewander/luacov-console) installed for that. |
| 47 |
If you want luacov's detailed report files, run the command with the `NOCLEAN` env set. |
| 48 |
For example `NOCLEAN=1 make testcov` |
| 49 |
|
| 50 |
[plenary.nvim]: https://github.com/nvim-lua/plenary.nvim |