forked from Ivy-Apps/ivy-wallet
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove unnecessary files & improve the contrubutors exp (Ivy-Apps#2918)
* Remove unused `package.json` related to DangerJS * Move `/assets` to `/docs/assets` * Move the CI troubleshooting guide to `/docs` * Simplify the PR template * Improve CONTRIBUTING.md * Fix typos & ambigious instructions in the PR template * Update CONTRIBUTING.md * Fix broken link to the "CI Troubleshooting" guide
- Loading branch information
1 parent
d5a1232
commit fa3f80e
Showing
12 changed files
with
74 additions
and
92 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# Troubleshooting CI failures | ||
|
||
If you see any of the PR checks failing (❌) go to [Actions](https://github.com/Ivy-Apps/ivy-wallet/actions) and find it there. Or simply click "Details" next to the failed check and explore the logs to see why it has failed. | ||
|
||
## Detekt | ||
[Detekt](https://detekt.dev/) is a static code analyzer for Kotlin that we use to enforce code readibility and good practices. | ||
|
||
**To run Detekt locally:** | ||
``` | ||
./gradlew detekt | ||
``` | ||
|
||
If the Detekt errors are caused by a legacy code, you can suppress them using a basline. | ||
|
||
**Suppress Detekt** (only if you're sure that Detekt is wrong) | ||
|
||
Add `@Suppress("ID_OF_THE_CHECK")` to ignore the error on a single place. For example: | ||
```kotlin | ||
@Suppress("FunctionMaxLength") | ||
fun veryVeryLongFunction() { | ||
// ... | ||
} | ||
``` | ||
|
||
**Detekt baseline** (not recommended) | ||
``` | ||
./scripts/detektBaseline.sh | ||
``` | ||
|
||
## Lint | ||
|
||
We use the [standard Android Lint](https://developer.android.com/studio/write/lint) plus [Slack's compose-lints](https://slackhq.github.io/compose-lints/) as an addition to enforce proper Compose usage. | ||
|
||
**To run Lint locally:** | ||
``` | ||
./scripts/lint.sh | ||
``` | ||
|
||
If the Lint errors are caused by a legacy code, you can suppress them using a basline. | ||
|
||
**Suppress Lint** (only if you're sure that Lint is wrong) | ||
|
||
Same as suppressing Detekt, just add `@Suppress("ID_OF_CHECK")`. | ||
|
||
**Lint baseline** (not recommended) | ||
``` | ||
./scripts/lintBaseline.sh | ||
``` | ||
|
||
## Unit tests | ||
|
||
If this job is failing this means that your changes break an existing unit test. You must identify the failing tests and fix your code. | ||
|
||
**To run the Unit tests locally:** | ||
``` | ||
./gradlew testDebugUnitTest | ||
``` |
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.