Add lint baseline, enable linting on CI, fix some reported errors #3291
No reviewers
Labels
No Label
device mi band 7
activity post processing
activity/health
Android 12
Android 13
android integrations
architecture
Bangle.js
bug
changes requested
charts
details not provided
developer documentation
device amazfit band 5
device amazfit bip
device amazfit cor
device Casio
device fossil
device garmin
device gtr 2e
device gts 2 mini
device h30
device hplus
device huami
device Huawei
device liveview
device mi band
device mi band 2
device mi band 3
device mi band 4
device mi band 5
device mi band 6
device no.1 f1
device pace
device pebble
device pebble 2
device pinetime infinitime
device request
device sony
device support
device watch 9
device xiaomi
discussion
documentation
duplicate
enhancement
feature request
Gadgetbridge
good first issue
help wanted
i am developing my own app can you help
icebox
intent api
internationalisation
invalid
needs work
network companion app
new device
no feedback
not a bug
notifications
one of the 1000 issues about disconnection
pairing/connecting
potentially fixed / confirm and close
question
research
security
seems abandoned
Solved, waiting for F-Droid release
suggest to close
task
user interface / UX
weather
wontfix
Zepp OS
No Milestone
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Freeyourgadget/Gadgetbridge#3291
Loading…
Reference in New Issue
There is no content yet.
Delete Branch "lint-fixes"
Deleting a branch is permanent. Although the deleted branch may exist for a short time before cleaning up, in most cases it CANNOT be undone. Continue?
This PR:
gradlew lint
and the Android Studio "Code Inspection" toollint-baseline.xml
of the remaining lint errors and warnings to be used by the linter as baselinegradlew lint
on every buildSome things to consider:
@ -216,10 +216,13 @@ android {
lintOptions {
abortOnError ABORT_ON_CHECK_FAILURE
Maybe set it to true here instead of setting it twice?
Whoops, I was too quick setting that... The
ABORT_ON_CHECK_FAILURE
variable is used in other places too, intask pmd()
andspotbugs {}
. I'm thinking the better fix would be to set the variable totrue
instead of hardcoding it inlintOptions {}
. Agree?@ -0,0 +1,16 @@
steps:
tests:
can you rename this to lint?
@ -0,0 +1,16 @@
steps:
tests:
can you rename this to lint?
Aside from the 2 minor comments, lgtm. The updated activities look to be unchanged and work as expected.
08232cd445
to3415236a4c
@ -0,0 +13,4 @@
when:
event:
exclude: cron
You should update this to
exclude: ['cron', 'deployment']
followingec9b423785
3415236a4c
todb20f51bcc
db20f51bcc
to17ecea226b