|
1 | 1 | # Code Style
|
| 2 | + |
2 | 3 | The following is a general guide on how to style your work so that the project
|
3 | 4 | remains consistent throughout all files. Please read this document in it's entirety
|
4 | 5 | and refer to it throughout the development of your contribution.
|
5 | 6 |
|
6 | 7 | 1. [General Guidelines](#general-guidelines)
|
7 |
| -2. [Commit Message Guidelines](#commit-message-guidelines) |
8 |
| -3. [Markdown Guidelines](#markdown-guidelines) |
9 |
| - |
10 |
| - |
| 8 | +2. [Markdown Guidelines](#markdown-guidelines) |
11 | 9 |
|
12 | 10 | ## General Guidelines
|
13 |
| -Listed is a example class used demonstrate general rules you should follow throughout the development of your contribution. |
14 | 11 |
|
15 |
| -- Docstrings are to follow reST (reStructuredText Docstring Format) as specified in [PEP 287](https://peps.python.org/pep-0287/) |
| 12 | +Listed is a example class used demonstrate general rules you should |
| 13 | +follow throughout the development of your contribution. |
| 14 | + |
| 15 | +- Docstrings are to follow reST (reStructuredText Docstring Format) |
| 16 | + as specified in [PEP 287](https://peps.python.org/pep-0287/) |
16 | 17 | - Private attributes are to be prefixed with an underscore
|
17 | 18 | - Use of [typing](https://docs.python.org/3/library/typing.html) type hints
|
18 | 19 | - All files are to use 2 space indenting
|
@@ -54,40 +55,16 @@ class ExampleClass:
|
54 | 55 | return value**2
|
55 | 56 | ```
|
56 | 57 |
|
57 |
| - |
58 |
| - |
59 |
| -## Commit Message Guidelines |
60 |
| -When committing, commit messages are prefixed with one of the following depending on the type of change made. |
61 |
| - |
62 |
| - - `feat:` when a new feature is introduced with the changes. |
63 |
| - - `fix:` when a bug fix has occurred. |
64 |
| - - `chore:` for changes that do not relate to a fix or feature and do not modify *source* or *tests*. (like updating dependencies) |
65 |
| - - `refactor:` for refactoring code that neither fixes a bug nor adds a feature. |
66 |
| - - `docs:` when changes are made to documentation. |
67 |
| - - `style:` when changes that do not affect the code, but modify formatting. |
68 |
| - - `test:` when changes to tests are made. |
69 |
| - - `perf:` for changes that improve performance. |
70 |
| - - `ci:` for changes that affect CI. |
71 |
| - - `build:` for changes that affect the build system or external dependencies. |
72 |
| - - `revert:` when reverting changes. |
73 |
| - |
74 |
| -Commit messages are also to begin with an uppercase character. Below list some example commit messages. |
75 |
| - |
76 |
| -```sh |
77 |
| -git commit -m "docs: Added README.md" |
78 |
| -git commit -m "revert: Removed README.md" |
79 |
| -git commit -m "docs: Moved README.md" |
80 |
| -``` |
81 |
| - |
82 |
| - |
83 | 58 | ## Markdown Guidelines
|
| 59 | + |
84 | 60 | Currently, documentation for this project resides in markdown files.
|
85 |
| - - Headings are to be separated with 3 lines |
86 |
| - - Use of HTML comments is appreciated |
87 |
| - - Use of HTML is permitted |
88 |
| - - [reference style links](https://www.markdownguide.org/basic-syntax/#reference-style-links) are not required by are appreciated |
89 |
| - - Exceedingly long lines are to be broken |
90 |
| - - The indents are to be 4 spaces |
| 61 | + |
| 62 | +- Headings are to be separated with 3 lines |
| 63 | +- Use of HTML comments is appreciated |
| 64 | +- Use of HTML is permitted |
| 65 | +- [Reference style links][reference-style-links] are not required by are appreciated |
| 66 | +- Exceedingly long lines are to be broken |
| 67 | +- The indents are to be 4 spaces |
91 | 68 |
|
92 | 69 | ```markdown
|
93 | 70 | <!--example markdown document-->
|
@@ -115,3 +92,5 @@ anim id est laborum. found [Lorem Ipsum Generator]
|
115 | 92 |
|
116 | 93 | [Lorem Ipsum Generator]: https://loremipsum.io/generator/
|
117 | 94 | ```
|
| 95 | + |
| 96 | +[reference-style-links]: https://www.markdownguide.org/basic-syntax/#reference-style-links |
0 commit comments