Permalink
Browse files

add README.contributing

  • Loading branch information...
1 parent 54ea891 commit 72f128156e3e8c6ece7baaef5fccb5ddf48eea35 @dae committed Aug 16, 2016
Showing with 74 additions and 1 deletion.
  1. +73 −0 README.contributing
  2. +1 −1 README.development
View
@@ -0,0 +1,73 @@
+Contributing Code
+==================
+
+For info on contributing things other than code, such as translations, decks
+and add-ons, please see http://ankisrs.net/docs/manual.html#contributing
+
+The goal of Anki 2.1.x is to bring Anki up to date with Python 3 and Qt 5,
+while changing as little else as possible. Modern Linux distros have started
+dropping support for Qt 4, so we need to keep changes to a minimum in order to
+get an update out faster.
+
+Also of consideration is that the Anki code is indirectly used by the mobile
+clients, which try their best to keep as close to the Anki code as possible so
+that future updates can be ported more easily. Refactoring code makes it
+harder for the mobile clients to track changes, so refactoring should be
+limited to times when it is necessary to address an important issue.
+
+Before sending a pull request or a patch, please check the following to
+increase your changes of the changes being accepted.
+
+Primarily Bugfixes
+-------------------
+
+Small patches that fix a specific problem and don't affect other functionality
+are likely to be merged if they meet the other requirements below. Larger
+changes are less likely to be accepted for 2.1.x - if in doubt, please ask
+before you begin work on them so your work does not go to waste.
+
+Examples of changes that are unlikely to be accepted:
+
+- Altering existing code unnecessarily. Your code may be more elegant than
+ what already exists, but it takes time for us to review the changes, may
+ habour unnoticed bugs, and makes maintaining the mobile clients more
+ difficult.
+- Adding code that is not used within Anki but it only for the benefit of
+ add-ons - such code is difficult to test and maintain.
+- Adding code that addresses niche issues - they are better handled in an
+ add-on.
+
+Maintaining Style
+------------------
+
+For consistency, changes should maintain the existing code style - camelCaps,
+<80 column lines, succinct variable names and so on.
+
+Tests Must Pass
+----------------
+
+Please check that tools/tests.sh passes all tests prior to submitting a
+change. If your change is not covered by existing tests, ideally you'll add a
+new test.
+
+Do One Thing
+-------------
+
+A patch or pull request should be the minimum necessary to address one issue.
+Please don't make a pull request for a bunch of unrelated changes, as they are
+difficult to review and will be rejected - split them up into separate
+requests instead.
+
+License
+-------
+
+As mentioned in the LICENSE file, we are only able to accept non-trivial
+patches or pull requests from people who have sent us a private message
+indicating that they license their changes under the BSD license.
+
+Add-ons
+========
+
+If you'd like to make more extensive changes, please consider writing an
+add-on instead, as add-ons have none of these restrictions and can implement
+whatever functionality in whatever style you wish.
View
@@ -54,7 +54,7 @@ $ ./runanki
If you get any errors, please make sure you don't have an older version of
Anki installed in a system location.
-Before contributing code, please read the LICENSE file.
+Before contributing code, please read README.contributing.
If you'd like to contribute translations, please see the translations section
of http://ankisrs.net/docs/manual.html#_contributing

0 comments on commit 72f1281

Please sign in to comment.