Skip to content
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

New documentation system #1766

Merged
merged 41 commits into from
Jul 22, 2019
Merged
Changes from 1 commit
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
d60061e
Revise document build system
mikee47 Jul 17, 2019
538e1d6
Update main makefiles
mikee47 Jul 17, 2019
969131a
Add docs to travis build
mikee47 Jul 16, 2019
ce111e1
Import images, convert existing text (including Wiki) to reStructured…
mikee47 Jul 8, 2019
79e08f0
Home: Edit contents readme into index.rst
mikee47 Jul 15, 2019
b7ef281
Emulator: update with note on Windows requirements
mikee47 Jul 15, 2019
2fcdd38
Add `Information` section, pull in debug images
mikee47 Jul 15, 2019
dc716a6
Add upgrade notes
mikee47 Jul 16, 2019
bd1ed92
Add `experimental` section
mikee47 Jul 15, 2019
13734d5
Add `tools` section
mikee47 Jul 16, 2019
2f767fd
Add `troubleshooting` section
mikee47 Jul 15, 2019
207f75d
Add `contribute` section, include new page on documentation system
mikee47 Jul 15, 2019
1f51b62
Edit coding style guide
mikee47 Jul 16, 2019
de3d9e4
Add `Quick Start` section, update guides
mikee47 Jul 17, 2019
7244df1
Add `api` section (to be completed), update Doxygen config
mikee47 Jul 15, 2019
d5ef8e5
Fix most doxygen warnings in code comments
mikee47 Jul 16, 2019
c36c2ee
Components: Move content from `features` into README files
mikee47 Jul 15, 2019
d6b5bff
Components: Add README files
mikee47 Jul 15, 2019
5edb1f7
Libraries: Pull in README files and fix titles
mikee47 Jul 17, 2019
1edab00
Libraries: Track down missing README files
mikee47 Jul 14, 2019
3c9a319
Samples: Move images into sample directories
mikee47 Jul 15, 2019
2aba79c
Samples: About to convert .md into .rst
mikee47 Jul 11, 2019
3560875
Samples: .md -> .rst
mikee47 Jul 15, 2019
8e8d032
Samples: Update README.rst files
mikee47 Jul 15, 2019
4b34797
Samples: Add 'todo' readme files for remaining samples
mikee47 Jul 11, 2019
3ad7d64
Reorganization of the content. The goal is to be able to learn about …
slav-at-attachix Jul 18, 2019
01ac58d
Minor changes to the content.
slav-at-attachix Jul 19, 2019
dec2a2a
Revise `HttpClient` sample readme to reflect new build system.
mikee47 Jul 18, 2019
8c13954
Minor doc fixes
mikee47 Jul 18, 2019
8e9e442
Add logo
mikee47 Jul 19, 2019
9a6c809
Generate index file containing reference information
mikee47 Jul 19, 2019
5a5412b
Move `Yeelight` into `Libraries`
mikee47 Jul 20, 2019
033a42d
Update environment variable lists
mikee47 Jul 20, 2019
5e3b300
Add section on device configuration to Esp8266 getting-started page
mikee47 Jul 20, 2019
8789bc6
Update macos start
mikee47 Jul 20, 2019
7405a26
Move samples and libraries index into root source directory
mikee47 Jul 20, 2019
fd17b28
Update `Basic_Ssl`, `Echo_Ssl` and `HttpClient` sample readme.
mikee47 Jul 20, 2019
7889fe6
Removed unnecessary level and stale text.
slav-at-attachix Jul 20, 2019
6fe9e6a
Add 'about' page with license info.
mikee47 Jul 21, 2019
db311d6
Add doc comments to `Print` class
mikee47 Jul 21, 2019
a06d6ec
Replace `api` section with generated doxygen HTML, including graphs
mikee47 Jul 21, 2019
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
Edit coding style guide
  • Loading branch information
mikee47 committed Jul 21, 2019
commit 1f51b626471103bd5d25929675530a9c252264a4
90 changes: 41 additions & 49 deletions docs/source/contribute/coding-style.rst
Original file line number Diff line number Diff line change
Expand Up @@ -144,39 +144,47 @@ long as 4 spaces. Below are the corresponding settings in clang-format.
Naming
------

+---------------------------+-------------------------------------------------------------------------------+-----------------------------------+
| Identifier type | Rules for naming | Examples |
+===========================+===============================================================================+===================================+
| Classes | |class-names| | :: |
| | | |
| | | class HttpClient {} |
| | | class HttpClientConnection {} |
+---------------------------+-------------------------------------------------------------------------------+-----------------------------------+
| Methods | |methods| | :: |
| | | |
| | | bind(); |
| | | getStatus(); |
+---------------------------+-------------------------------------------------------------------------------+-----------------------------------+
| Variables | |local-vars| | :: |
| | | |
| | | int i; |
| | |varnames| | char c; |
| | | WebsocketClient* client; |
+---------------------------+-------------------------------------------------------------------------------+-----------------------------------+
| Constants | |constants| | :: |
| | | |
| | | #define MAX_PARTICIPANTS 10 |
+---------------------------+-------------------------------------------------------------------------------+-----------------------------------+

.. |methods| replace:: Methods must be either verbs in lowerCamelCase, or a multi-word name that begins with a verb in lowercase; that is, with the first letter lowercase and the first letters of subsequent words in uppercase.

.. |class-names| replace:: Class names must be nouns in UpperCamelCase, with the first letter of every word capitalised. Use whole words — avoid acronyms and abbreviations (unless the abbreviation is much more widely used than the long form, such as URL or HTML).

.. |local-vars| replace:: Local variables, instance variables, and class variables must also be written in lowerCamelCase. Variable names must not start with, end with or contain underscore (\_) or dollar sign ($) characters. This is in constrast to some coding conventions which prefix all instance variables with underscore, however this is reserved by the C++ standard and can create problems.

.. |varnames| replace:: Variable names should be short yet meaningful. The choice of a variable name should be mnemonic — that is, designed to indicate to the casual observer the intent of its use. One-character variable names should be avoided except for temporary “throwaway” variables. Common names for temporary variables are i, j, k, m, and n for integers; c, d, and e for characters.

.. |constants| replace:: Constants must be written in uppercase characters separated by underscores. Constant names may contain digits if appropriate, but not as the first character.
+---------------------------+-----------------------+-----------------------------------+
| Identifier type | Rules for naming | Examples |
+===========================+=======================+===================================+
| Classes | |class-names| | :: |
| | | |
| | | class HttpClient {} |
| | | class HttpClientConnection {} |
+---------------------------+-----------------------+-----------------------------------+
| Methods | |methods| | :: |
| | | |
| | | bind(); |
| | | getStatus(); |
+---------------------------+-----------------------+-----------------------------------+
| Variables | |local-vars| | :: |
| | | |
| | | int i; |
| | |varnames| | char c; |
| | | WebsocketClient* client; |
+---------------------------+-----------------------+-----------------------------------+
| Constants | |constants| | :: |
| | | |
| | | #define MAX_PARTICIPANTS 10 |
+---------------------------+-----------------------+-----------------------------------+

.. |methods| replace:: Methods must be either verbs in lowerCamelCase, or a multi-word name that begins with a verb in lowercase;
that is, with the first letter lowercase and the first letters of subsequent words in uppercase.

.. |class-names| replace:: Class names must be nouns in UpperCamelCase, with the first letter of every word capitalised.
Use whole words — avoid acronyms and abbreviations (unless the abbreviation is much more widely used than the long form, such as URL or HTML).

.. |local-vars| replace:: Local variables, instance variables, and class variables must also be written in lowerCamelCase.
Variable names must not start with, end with or contain underscore (\_) or dollar sign ($) characters.
This is in constrast to some coding conventions which prefix all instance variables with underscore,
however this is reserved by the C++ standard and can create problems.

.. |varnames| replace:: Variable names should be short yet meaningful. The choice of a variable name should be mnemonic — that is,
designed to indicate to the casual observer the intent of its use. One-character variable names should be avoided except for
temporary “throwaway” variables. Common names for temporary variables are i, j, k, m, and n for integers; c, d, and e for characters.

.. |constants| replace:: Constants must be written in uppercase characters separated by underscores.
Constant names may contain digits if appropriate, but not as the first character.


C++ Standard
Expand Down Expand Up @@ -295,22 +303,6 @@ For readability put always spaces before assignment operators.
Other Elements
==============

#include guards
---------------

Please follow the standard naming convention. Example:

Filename: ``SmingCore/Network/Http/Websocket/WsCommandHandlerResource.h``

::

#ifndef _SMING_CORE_NETWORK_HTTP_WEBSOCKET_WS_COMMAND_HANDLER_RESOURCE_H_
#define _SMING_CORE_NETWORK_HTTP_WEBSOCKET_WS_COMMAND_HANDLER_RESOURCE_H_

...

#endif /* _SMING_CORE_NETWORK_HTTP_WEBSOCKET_WS_COMMAND_HANDLER_RESOURCE_H_ */

Standard file headers
---------------------

Expand Down