]> granicus.if.org Git - libevent/blob - CONTRIBUTING.md
cmake: do influence CMAKE_DEBUG_POSTFIX of the outer project (if any)
[libevent] / CONTRIBUTING.md
1 # Contributing to libevent
2
3 ## Coding style
4
5 First and most generic rule: **just look around**.
6
7 But, we have a script for checking patches/files/git-refs:
8 ```shell
9 # Chech HEAD git ref
10 ./checkpatch.sh -r
11 ./checkpatch.sh -r HEAD
12
13 # Check patch
14 git format-patch --stdout -1 | ./checkpatch.sh -p
15 git show -1 | ./checkpatch.sh -p
16
17 # Or via regular files
18 git format-patch --stdout -2
19 ./checkpatch.sh *.patch
20
21 # Over a file
22 ./checkpatch.sh -d event.c
23 ./checkpatch.sh -d < event.c
24
25 # And print the whole file not only summary
26 ./checkpatch.sh -f event.c
27 ./checkpatch.sh -f < event.c
28
29 # See
30 ./checkpatch.sh -h
31 ```
32
33 ## Testing
34 - Write new unit test in `test/regress_{MORE_SUITABLE_FOR_YOU}.c`
35 - `make verify`
36
37 ## Asking Questions
38 It's all right to have questions! Instead of filing an issue here, go ahead and leave a message in our [Gitter Room](https://gitter.im/libevent/libevent)