test_poll: preserve original trap(:USR1) handler
[kgio.git] / HACKING
blob5d485beb73f91bc90ab7ced9b523004db9923b65
1 = kgio Hacker's Guide
3 === Documentation
5 We use the latest version of {wrongdoc}[http://bogomips.org/wrongdoc] as
6 much as possible.
8 Please wrap documentation at 72 characters-per-line or less (long URLs
9 are exempt) so it is comfortably readable from terminals.
11 When referencing mailing list posts, use
12 "http://mid.gmane.org/$MESSAGE_ID" if possible since the Message-ID
13 remains searchable even if Gmane becomes unavailable.
15 === Code Compatibility
17 We target Ruby 1.8.6+, 1.9.1+ and Rubinius 1.1+ and their
18 respective C APIs.
20 All of our C code should be compatible with all reasonably modern Unices
21 and should run on compilers supported by the versions of Ruby we target.
23 We will NEVER directly support non-Free platforms under any circumstances.
25 Our C code follows K&R indentation style (hard tabs, tabs are always 8
26 characters wide) and NOT the indentation style of Matz Ruby.
28 == Contributing
30 Contributions are welcome in the form of patches, pull requests, code
31 review, testing, documentation, user support or any other feedback.  The
32 {kgio mailing list}[mailto:kgio@librelist.org] is the
33 central coordination point for all user and developer feedback and bug
34 reports.
36 === Submitting Patches
38 Follow conventions already established in the code and do not exceed 80
39 characters per line.
41 Inline patches (from "git format-patch -M") to the mailing list are
42 preferred because they allow code review and comments in the reply to
43 the patch.
45 We will adhere to mostly the same conventions for patch submissions as
46 git itself.  See the Documentation/SubmittingPatches document
47 distributed with git on on patch submission guidelines to follow.  Just
48 don't email the git mailing list or maintainer with kgio patches :)
50 == Running Development Versions
52 It is easy to install the contents of your git working directory:
54 Via RubyGems (RubyGems 1.3.5+ recommended for prerelease versions):
56   gmake install-gem
58 Without RubyGems (via setup.rb):
60   gmake install
62 It is not at all recommended to mix a RubyGems installation with an
63 installation done without RubyGems, however.
65 === Tests
67 We use GNU make to run tests in parallel.  test/unit/parallel didn't
68 exist for old versions of Ruby before 1.9.3.  Users of GNU-based systems
69 (such as GNU/Linux) usually have GNU make installed as "make" instead of
70 "gmake".
72 Running the entire test suite with 4 tests in parallel:
74   gmake -j4 test
76 Running just one unit test:
78   gmake test/test_poll.rb