Contribution guidelines in the nRF Connect SDK
Any individual or company can choose to contribute to the nRF Connect SDK codebase. Contributions are welcome but entirely optional, as the licenses used by the nRF Connect SDK allow for free modification of the source code without a requirement to contribute the changes back.
The nRF Connect SDK contribution guidelines are modelled on those adopted in Zephyr. The following table lists the major contribution guidelines and summarizes the similarities and differences between Zephyr and the nRF Connect SDK.
Note
If you want to contribute to the Zephyr codebase, create a PR upstream in the official Zephyr repository instead of a PR that targets the sdk-zephyr downstream fork repository.
Contribution Guidelines in Zephyr |
Description |
Differences with the nRF Connect SDK |
---|---|---|
Check Licensing |
Apache 2.0 in Zephyr. |
LicenseRef-Nordic-5-Clause in the nRF Connect SDK. |
Respect Copyright notices |
Recognize the ownership of the original work according to the Linux Foundation’s Community Best Practice for Copyright Notice. |
Zephyr guidelines valid in the nRF Connect SDK. |
The DCO is required for every contribution made by every developer. |
Zephyr guidelines valid in the nRF Connect SDK. |
|
Gain familiarity with development environment and tools |
The environment should be set up as recommended in the official documentation and you should use tools that are supported and compatible with the project, such as Git and CMake.
You also need to create an account on GitHub.
|
The nRF Connect SDK also requires familiarity with the nRF Connect SDK toolchain and Additions specific to the nRF Connect SDK to the configuration and build system. |
Gain familiarity with source tree structure |
In Zephyr, this means respecting the Source Tree Structure and the purpose of main files and directories in order to avoid redundancy. |
While the guidelines are valid for the nRF Connect SDK, the SDK uses a different repository organization. |
Check issues before contributing |
When contributing, check the existing pull requests and issues in the respective repository in order to avoid redundancy. |
In the nRF Connect SDK, verify also the existing Known issues. |
Run local scripts before contributing |
Run a series of local scripts to verify the code changes that are to be contributed. |
Zephyr guidelines valid in the nRF Connect SDK. |
Respect the coding style |
Follow a series of coding style recommendations and Coding Guidelines. |
Zephyr guidelines valid in the nRF Connect SDK. |
Document changes to code and API |
Follow Documentation Guidelines and instructions for testing changes to documentation locally. |
In the nRF Connect SDK, documentation guidelines are more detailed than in Zephyr, as described in nRF Connect SDK documentation. |
Make small, controlled changes |
Follow a Contribution Workflow based on small, incremental changes. See also Contributor Expectations. |
Zephyr guidelines valid in the nRF Connect SDK. |
Write clear commit messages |
See Zephyr’s Commit Message Guidelines for more information. |
Zephyr guidelines valid in the nRF Connect SDK. |