When contributing to SerenityOS, make sure that the changes you wish to make are in line with the project direction. If you are not sure about this, open an issue first, so we can discuss it.
For your first couple of PRs, start with something small to get familiar with the project and its development processes. Please do not start by adding a new application, library or other large component.
Everyone is welcome to work on the project, and while we have lots of fun, it's a serious kind of fun. :^)
Join our Discord server: SerenityOS Discord
Unlike many other software projects, SerenityOS is not concerned with gaining the largest possible userbase. Its target audience is its own developers. As such, we have limited interest in feature requests from non-contributors.
That said, please do file any bugs you find, keeping the following in mind:
#build-problems channel on Discord.In SerenityOS, we treat human language as seriously as we do programming language.
The following applies to all user-facing strings, code, comments, and commit messages:
Everyone is encouraged to make use of tooling (spell checkers, etc) to make this easier.
When possible, please include tests when fixing bugs or adding new features.
Nobody is perfect, and sometimes we mess things up. That said, here are some good dos & don'ts to try and stick to:
Do:
AK containers in all code.clang-format (version 18 or later) to automatically format C++ files. See AdvancedBuildInstructions.md for instructions on how to get an up-to-date version if your OS distribution does not ship clang-format-18.LibAudio, HackStudio, Base, Kernel, ConfigServer, catUserland" or "Utilities", except for generic changes that affect a large portion of code within these directories.LibGUI: Brief description of what's being changed in FooWidget rather than FooWidget: Brief description of what's being changed+, e.g. LibJS+LibWeb+Browser: ...optipng -strip all on them to optimize and strip away useless metadata - this can reduce file size from multiple kilobytes to a couple hundred bytes.Don't:
While unadvertised PRs may get randomly merged by curious maintainers, you will have a much smoother time if you engage with the community on Discord.
Ping them right away if it's something urgent! If it's less urgent, advertise your PR on Discord (#code-review) and ask if someone could review it.
Maintainership is by invitation only and does not correlate with any particular metric.
Yes, we have a "stalebot" that will mark untouched PRs as "stale" after 21 days, and close them after another 7 days if nothing happens.
In theory, the best person to speak with is whoever wrote most code adjacent to what you're working on. In practice, asking in one of the development channels on Discord is usually easier/better, since that allows many people to join the discussion.
It's definitely better to ask on Discord. Due to the volume of GitHub notifications, many of us turn them off and rely on Discord for learning about review requests.
The repository contains a file called .pre-commit-config.yaml that defines several 'commit hooks' that can be run automatically just before and after creating a new commit. These hooks lint your commit message, and the changes it contains to ensure they will pass the automated CI for pull requests. To enable these hooks firstly follow the installation instructions available at https://pre-commit.com/#install and then enable one or both of the following hooks:
pre-commit install
pre-commit install --hook-type commit-msg
Sometimes good PRs get abandoned by the author for one reason or another. If the PR is fundamentally good, but the author is not responding to requests, the PR may be manually integrated with minor changes to code and commit messages.
To make this easier, we do appreciate it if folks enable the "Allow edits from maintainers" flag on their pull requests.
SerenityOS's goal is to enable collaboration between as many groups as reasonably possible, and we welcome contributions that make the project more accessisble to people.
However, SerenityOS is intended to be a purely technical exercise, in the sense of it not being meant to invoke any sociopolitical change. We explicitly try to avoid drama or getting involved in "external" culture wars, and can reject changes that we feel to be sensitive.
For instance, we can reject changes promoting dogwhistles, religious beliefs—which are unambiguously off-topic—or real-world political candidates.
We may miss the mark sometimes, but we encourage good-faith dialogue over anger.