-
Notifications
You must be signed in to change notification settings - Fork 45
Contributing
Contributions are always welcome, this page will be focused on Contributing or setting this project up in Android Studio.
Assuming the project has already been Cloned via Android Studio or opened from downloading from git or Github.
Android Studio may be able to automatically grab the latest SDK dependencies based on the project, however if it does not for any reason, here is a list of what SDK components should be downloaded through the SDK manager.
- Android SDK Build-Tools
- NDK (Side by side)
- Cmake
- Android SDK Platform-Tools
This project uses a bit of an opinionated code style, this may change over time while the codebase starts to mature.
Most of the enforced formatting can be done through the formatKotlin gradle task applied in the project. This will apply rules we get for ktLint to apply throughout the project. Though some formatting will fail or unable to be applied.
See the .editorconfig for applied rules.
Some formatting and style that may need to be applied manually.
- Settings > Editor > Code Style > Kotlin: Tab Size, Indent, Continuation Intent should be set to
4 - No wilcards, such as:
import kotlinx.coroutines.*. ktLint will fail when building orformatKotlinis used. Replace any wildcards with the full import.
(...to be continued)
We have a GitHub Action runner that will check project for any lint errors. If the project hasn't been linted before submission. The approved run will fail for rules that we don't have bypassed above.
If you use Android Studio for development, there are two options that you can run easily to properly lint the app. In your Run/Debug configuration (left of the Run button) should be two options.
-
Pluvia [formatKotlin]which will automatically try and fix formatting. -
Pluvia [lintKotlin]which will run and list any formatting issues.
Any build failures will show you where the linting failed at. Correct as needed and try again until its successful.
If you prefer gradle to build the project, you can use these params to do the same.
./gradlew :app:formatKotlin./gradlew :app:lintKotlin