Thanks for contributing to this project. Please read through this page to help you understand what to expect from the process.
This project is governed by the Signaletic Code of Conduct. All contributors are expected to respect these social practices.
To contribute a bug report or feature request:
- Search our issues to confirm that the issue hasn't already been reported.
- Create a new bug report, following the guidance in the issue template.
- Discuss the bug report in the ticket and in community forums.
If you would like to contribute a code or documentation change to address an issue or add new features or functionality:
- First file an issue in the project's issue tracker as outlined above. This should describe the nature of work, what's involved in implementing it, and any questions or challenges that you're aware of in the task.
- Fork the project repository.
- Create a branch based on the latest code in the
main
branch. - Make the changes described in the associated ticket (see "Coding Guidelines" below).
- Submit a pull request against the project repository's
main
branch. If the pull request is meant to resolve a known issue, include text like "Resolves #18", "Fixes #28" in the pull request title and in appropriate commit messages. - Work with reviewers to discuss your changes and address any feedback.
In general, pull requests should:
- Provide meaningful commit messages (see below).
- Include tests verifying the changes (see below).
- Update or add markdown documentation for API changes.
- Provide documentation for new functions.
- Contain only your own original creative work, or the work of other authors who are clearly attributed (with links) that is shared under a compatible open source license (please ask if in doubt)
All commit log messages should include the following information:
- A reference to the GitHub issue this commit applies to (at the beginning of the first line).
- A meaningful, but short description of the change.
A good commit message might look like:
commit -am "gh-12: Initial implementation of neutron flow reversal."
commit -am "gh-12: Adds documentation based on PR feedback."
The tests for this package are currently written using Unity, and can be run for both native and Web Assembly builds. See the project README for more details.
Signaletic does not yet include any automated lint checks. In the meantime, here are some basic stylistic guidelines:
- Use four spaces for indentation
- Avoid platform-varying types (such as
short
orlong
) in favour of the C99 fixed-width types (e.g.int16_t
andint32_t
) - Pointers should be defined as
float* foo
rather thanfloat *foo
- Avoid unnecessary use of
typedef
. Usestruct foo {}
instead oftypedef struct {} foo;
- All definitions should be namespaced. Core Signaletic functions, structs, enums, variable definitions, etc. begin with the prefix
sig_
. - Provide a
struct sig_Status
as the last argument to any function that may cause errors
Stylistic conventions very often raise bike shed issues for communities. While these may not be your preferred choices, hopefully we can all agree to disagree. If you find that you are having trouble satisfying one or more conventions, or if you think a stylistic change is warranted, please feel free to raise it in a way that is respectful of the sometimes distracting and polarizing nature of such debates.