diff options
author | TingPing <tngpng@gmail.com> | 2013-06-23 07:29:26 -0300 |
---|---|---|
committer | TingPing <tngpng@gmail.com> | 2013-06-23 07:29:26 -0300 |
commit | 328593470379cfe1bade308145dc26b703d97586 (patch) | |
tree | 9d67d8e7d1615e2f7a93fab26fc017079817ade6 /share/doc | |
parent | c7d1102c61fd3efe8d46c6b0d714d6de2760db5a (diff) |
Update hacking.md
Diffstat (limited to 'share/doc')
-rw-r--r-- | share/doc/hacking.md | 41 |
1 files changed, 10 insertions, 31 deletions
diff --git a/share/doc/hacking.md b/share/doc/hacking.md index a63dc044..c5373405 100644 --- a/share/doc/hacking.md +++ b/share/doc/hacking.md @@ -9,14 +9,16 @@ Just some tips if you're going to help with HexChat code (patches etc): * Try to stick to the same consistant coding style (vertically aligned braces, a space after if, while, functions etc.): - <pre>void - routine (void) +```C +void +routine (void) +{ + if (function (a, b, c)) { - if (function (a, b, c)) - { - x = a + 1; - } - }</pre> + x = a + 1; + } +} +``` * Don't use "//" C++ style comments, some compilers don't like them. @@ -30,28 +32,5 @@ Just some tips if you're going to help with HexChat code (patches etc): * Don't read() from sockets, use recv() instead. -* Please provide unified format diffs (run diff -u). - -* Call your patch something more meaningfull than hexchat.diff. - -* To make a really nice and clean patch, do something like this: - - * Have two directories, unpacked from the original archive: - - <pre>hexchat-2.9.0/ - hexchat-2.9.0p1/</pre> - - * Then edit/compile the hexchat-2.9.0p1 directory. To create a patch: - - * Windows: - - <pre>rmdir /q /s hexchat-2.9.0p1/win32/build - rmdir /q /s hexchat-2.9.0p1/win32/build-xp - diff -ruN --strip-trailing-cr hexchat-2.9.0 hexchat-2.9.0p1 > hexchat-something.diff - </pre> - - * Unix: - - <pre>diff -ruN hexchat-2.9.0 hexchat-2.9.0p1 > hexchat-something.diff</pre> - +* Patches are only accepted as a Github Pull request: https://help.github.com/articles/using-pull-requests |