File tree Expand file tree Collapse file tree 3 files changed +25
-1
lines changed Expand file tree Collapse file tree 3 files changed +25
-1
lines changed Original file line number Diff line number Diff line change 3535
3636 - name : Run tests
3737 run : make test
38+
39+ lint :
40+ runs-on : ubuntu-latest
41+
42+ if : " !contains(github.event.head_commit.message, '[ci skip]')"
43+
44+ steps :
45+ - name : Check out code
46+ uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
47+ - uses : actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # v5.4.0
48+ with :
49+ go-version-file : " go.mod"
50+ - name : Switch to Java 17 # Note: 17 is pre-installed on ubuntu-latest
51+ uses : actions/setup-java@3a4f6e1af504cf6a31855fa899c6aa5355ba6c12 # v4.7.0
52+ with :
53+ distribution : " temurin"
54+ java-version : " 17"
55+
56+ - name : Run fmt-check
57+ run : make fmt-check
Original file line number Diff line number Diff line change @@ -321,7 +321,8 @@ fmt: gradle-dependencies ## Format the Android code
321321
322322.PHONY : fmt-check
323323fmt-check : gradle-dependencies # # Check the Android code is formatted
324- (cd android && ./gradlew ktfmtCheck)
324+ (cd android && ./gradlew ktfmtCheck) \
325+ || (echo -e " \033[1;31mfmt-check failed. Run 'make fmt' to fix.\033[0m" && exit 1)
325326
326327.PHONY : emulator
327328emulator : # # Start an android emulator instance
Original file line number Diff line number Diff line change 5858The ktmft plugin on the default setting should be used to autoformat all Java, Kotlin
5959and XML files in Android Studio. Enable "Format on Save".
6060
61+ This is checked in CI using ` make fmt-check ` , and you can also run reformat the files locally
62+ using: ` make fmt `
63+
6164### Docker
6265
6366If you wish to avoid installing software on your host system, a Docker based development strategy is available, you can build and start a shell with:
You can’t perform that action at this time.
0 commit comments