Skip to content

Commit 36c5c3b

Browse files
committed
Add Developer Certificate of Origin (DCO)
- See https://developercertificate.org/ Signed-off-by: Thomas Lauf <thomas.lauf@tngtech.com>
1 parent d433c70 commit 36c5c3b

3 files changed

Lines changed: 96 additions & 12 deletions

File tree

CONTRIBUTING.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Contributing to libshared
2+
3+
Code contributions are only accepted as pull-requests.
4+
In general your contributions have to be associated with an issue on our [GitHub issue tracker](https://github.com/GothenburgBitFactory/libshared/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen).
5+
6+
Any code contributions should have sufficient test coverage.
7+
8+
When writing bug-fixes, first write a test to confirm it, then add the commit to fix it.
9+
When implementing a feature, make sure its behavior is defined by tests.
10+
11+
Tests are likely the most useful contributions of all, because they not only improve the quality of the code, but prevent future regressions, therefore maintaining quality of subsequent releases.
12+
13+
Nevertheless, all code has to adhere to the coding style guidelines and project architecture.
14+
See the respective section below.
15+
16+
If you want to go the extra mile, update the ChangeLog and add your name to the AUTHORS file in the right place.
17+
18+
By contributing, you are declaring that you have the right to submit the code under the project licensing terms.
19+
Therefore, commits should be signed off according to the [DCO](DCO) (use `-s` / `--signoff` flag when committing).
20+
21+
## Coding style
22+
23+
The general guideline is simply this:
24+
25+
> Make all changes and additions such that they blend in perfectly with the surrounding code, so it looks like only one person worked on the source, and that person is rigidly consistent.
26+
27+
To be a little more explicit, the common elements across the languages are:
28+
29+
* Indent code using two spaces, no tabs
30+
* With Python, follow PEP8 as much as possible
31+
* Surround operators and expression terms with a space
32+
* No cuddled braces
33+
* No need to stick slavishly to 80 characters per line, but do not make them overly long (rule of thumb: *One sentence/statement per line*)!
34+
* Class names are capitalized, variable names are not
35+
36+
We target Python 3 so that our test suite runs on the broadest set of platforms.
37+
38+
We can safely target C++17 because all the default compilers on our supported platforms are ready.
39+
Feel free to use C++20 provided that all build platforms support this.

DCO

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
## Sign your work - the Developer's Certificate of Origin
2+
The sign-off is a simple line at the end of the explanation for the patch, which certifies that you wrote it or otherwise have the right to pass it on as an open-source patch.
3+
The rules are pretty simple: if you can certify the below (from developercertificate.org):
4+
5+
> Developer's Certificate of Origin 1.1
6+
>
7+
> By making a contribution to this project, I certify that:
8+
>
9+
> (a) The contribution was created in whole or in part by me and I
10+
> have the right to submit it under the open source license
11+
> indicated in the file; or
12+
>
13+
> (b) The contribution is based upon previous work that, to the best
14+
> of my knowledge, is covered under an appropriate open source
15+
> license and I have the right under that license to submit that
16+
> work with modifications, whether created in whole or in part
17+
> by me, under the same open source license (unless I am
18+
> permitted to submit under a different license), as indicated
19+
> in the file; or
20+
>
21+
> (c) The contribution was provided directly to me by some other
22+
> person who certified (a), (b) or (c) and I have not modified
23+
> it.
24+
>
25+
> (d) I understand and agree that this project and the contribution
26+
> are public and that a record of the contribution (including all
27+
> personal information I submit with it, including my sign-off) is
28+
> maintained indefinitely and may be redistributed consistent with
29+
> this project or the open source license(s) involved.
30+
31+
#### DCO Sign-Off Methods
32+
33+
The DCO requires a sign-off message in the following format appear on each commit in the pull request:
34+
35+
> Signed-off-by: Random J Developer <random@developer.example.org>
36+
37+
using your real name (sorry, no pseudonyms or anonymous contributions.)
38+
39+
The DCO text can either be manually added to your commit body, or you can add either **-s** or **--signoff** to your usual git commit commands.
40+
If you forget to add the sign-off you can also amend a previous commit with the sign-off by running **git commit --amend -s**.
41+
If you've pushed your changes to GitHub already you'll need to force push your branch after this with **git push -f**.
42+
43+
44+
#### Alternative Sign-Off Methods in rare cases
45+
46+
If it is really no option for you to disclose your real name and email address, there might be a chance that you can get your contribution accepted.
47+
In this case please contact the maintainers directly and verify the adherence to the DCO of the contribution manually.
48+
This might include quite some legal overhead for both parties.

README.md

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
1-
libshared
2-
=========
1+
# libshared
32

4-
A git submodule used by multiple projects. Not to be released or packaged
5-
independently. All project tarballs will include libshared, so this is a
6-
development-only internal project.
3+
A Git submodule used by multiple projects, mainly Taskwarrior and Timewarrior.
4+
Not to be released or packaged independently.
75

8-
Branching
9-
---------
6+
All project tarballs will include libshared, so this is a development-only internal project.
107

11-
Development for libshared is done on the master branch only.
8+
# Development
129

13-
Each time a project is released that uses libshared, an appropriate tag is
14-
added to the corresponding commit.
10+
Development for libshared is done on the `master` branch only.
11+
See [CONTRIBUTING.md](CONTRIBUTING.md) for details on how to contribute.
1512

16-
A project may choose to release with any libshared commit.
13+
Each time a project is released that uses libshared, an appropriate tag is added to the corresponding commit.
1714

18-
---
15+
A project may choose to release with any libshared commit.

0 commit comments

Comments
 (0)