How to Contribute to Welma¶
Contributions are very welcome. The checklist below summarizes the important information for any new contribution.
If you would like to contribute a new feature, make sure to discuss it beforehand with the Welma team, to avoid duplicating effort, and to keep a consistent direction for the project:
- Pierre Gal (pgal@witekio.com)
- Nicolas Launet (nlaunet@witekio.com)
- Frederic Hoerni (fhoerni@witekio.com)
- Zakaria Zidouh (zzidouh@witekio.com)
Coding Style¶
- Follow the Recipe Style Guide of Yocto Project.
- Use 4-space indentation for python and shell snippets.
- Wrap lines at 80 characters (this is not only to deal with small screens but also to facilitate review after a small change in a line).
- In comments, add a space after the leading
#
character. -
Source files shall end with an newline character (LF, \n, ASCII 0x0a)
-
In
conf/layer.conf
, nameBBFILE_COLLECTIONS
with suffix-layer
and without prefixmeta-
. Eg: -
Name your images
*-image*
, as some tools (eg:runqemu
) expect this pattern. Eg:
Add Support for a New Machine¶
-
Add machine specific configuration:
- In a repository named
meta-welma-<vendor-suffix>
(the suffix being defined on a case-by-case basis) - Use BSP components supplied by open-source communities or by vendors (board manufacturers), as much as possible, to minimize future maintenance costs.
- See Support your machine (Arm)
- In a repository named
-
Update/Create informative files:
- license-digest
- templates
-
In the end, the following must be achieved:
- one can connect to the development image via SSH to
169.254.0.1
orfe80::1
- if the board has a HW watchdog, then it must be configured and started before the kernel
- the device has fixed MAC address (that does not change on reboot)
- demo images run succesfully (
meta-demo-headless
,meta-demo-graphics/*
) - swupdate, mender, mender-connected integrations
- one can connect to the development image via SSH to
-
Create automatic tests (repository:
welma-test
): -
Add related jobs in
ci
: build, cvescan, test -
Update
welma-documentation
, and create a page dedicated to the new machine, with:- Board identification
- Boot sequence: description of the boot sequence on Welma
- First installation
- Regular boot: how to configure the machine for a regular boot
- Appendix:
- Practical instructions for developers: connecting the board, boot mode switches...
- Specific technical choices (watchdog...)
Git Workflow¶
Our Git workflow is as follows:
The key aspects are:
- Make an empty first commit.
-
Work in branches prefixed by
feature/
orfix/
:- Make clean commits as they are not automatically squashed during the merging and will remain visible.
- Keep a linear git history by rebasing
feature/
orfix/
branches ontodevelop
.
-
Branches
feature/
orfix/
are merged intodevelop
:- Do merge requests and peer reviews.
- Make a merge commit (no fast-forward).
In repositories that stick to Yocto revisions:
- Branch
master
is namedkirkstone
orscarthgap
depending on the Yocto branch alignment. - Branch
develop
is namedkirkstone-next
orscarthgap-next
.