|
| 1 | +# Contributing Guidelines |
| 2 | + |
| 3 | +One can contribute to the project by reporting issues or submitting changes via pull request. |
| 4 | + |
| 5 | +## Reporting issues |
| 6 | + |
| 7 | +Please use [GitHub issues](https://github.com/Kotlin/binary-compatibility-validator/issues) for filing feature requests and bug reports. |
| 8 | + |
| 9 | +Questions about usage and general inquiries are better suited for StackOverflow or the [#library-development](https://kotlinlang.slack.com/archives/C8C4JTXR7) channel in KotlinLang Slack. |
| 10 | + |
| 11 | +## Submitting changes |
| 12 | + |
| 13 | +Submit pull requests [here](https://github.com/Kotlin/binary-compatibility-validator/pulls). |
| 14 | +However, please keep in mind that maintainers will have to support the resulting code of the project, |
| 15 | +so do familiarize yourself with the following guidelines. |
| 16 | + |
| 17 | +* All development (both new features and bug fixes) is performed in the `develop` branch. |
| 18 | + * The `master` branch contains the sources of the most recently released version. |
| 19 | + * Base your PRs against the `develop` branch. |
| 20 | + * The `develop` branch is pushed to the `master` branch during release. |
| 21 | + * Documentation in markdown files can be updated directly in the `master` branch, |
| 22 | + unless the documentation is in the source code, and the patch changes line numbers. |
| 23 | +* If you make any code changes: |
| 24 | + * Follow the [Kotlin Coding Conventions](https://kotlinlang.org/docs/reference/coding-conventions.html). |
| 25 | + * Use 4 spaces for indentation. |
| 26 | + * Use imports with '*'. |
| 27 | + * [Build the project](#building) to make sure it all works and passes the tests. |
| 28 | +* If you fix a bug: |
| 29 | + * Write the test that reproduces the bug. |
| 30 | + * Fixes without tests are accepted only in exceptional circumstances if it can be shown that writing the |
| 31 | + corresponding test is too hard or otherwise impractical. |
| 32 | +* Comment on the existing issue if you want to work on it. Ensure that the issue not only describes a problem, but also describes a solution that has received positive feedback. Propose a solution if none has been suggested. |
| 33 | + |
| 34 | +## Building |
| 35 | + |
| 36 | +In order to build and run tests in the project in IDE, two prerequisites are required: |
| 37 | + |
| 38 | +* Java 11 or above in order to use the latest ASM |
| 39 | +* All build actions in the IDE should be delegated to Gradle |
| 40 | + |
| 41 | +To run tests with Gradle, you can execute `./gradlew check`. That will run both unit and functional tests, and it also will check the public API changes. |
| 42 | + |
| 43 | +### Updating the public API dump |
| 44 | + |
| 45 | +* Run following commands to update the public API: |
| 46 | + * Run `./gradlew apiDump` to update API index files. |
| 47 | + * Commit the updated API indexes together with other changes. |
0 commit comments