Skip to content

Commit 5724ecb

Browse files
committed
Modernize build configuration
1 parent f11fbd3 commit 5724ecb

16 files changed

Lines changed: 292 additions & 267 deletions

.github/workflows/build.yml

Lines changed: 16 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Build
1+
name: Code Quality and Build Checks
22

33
on:
44
push:
@@ -9,24 +9,23 @@ on:
99
pull_request:
1010

1111
concurrency:
12-
group: ${{ github.workflow }}-${{ github.ref }}
12+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
1313
cancel-in-progress: true
1414

1515
jobs:
1616
build:
17+
name: Check code format and build
1718
runs-on: ubuntu-latest
18-
steps:
19-
- name: Clone repo
20-
uses: actions/checkout@v4
2119

22-
- name: Validate Gradle Wrapper
23-
uses: gradle/wrapper-validation-action@v2
20+
steps:
21+
- name: Checkout Repository
22+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2423

25-
- name: Set up JDK
26-
uses: actions/setup-java@v4
24+
- name: Set up JDK 21
25+
uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5.2.0
2726
with:
28-
java-version: 17
29-
distribution: adopt
27+
java-version: 21
28+
distribution: temurin
3029

3130
- name: Install native build dependencies
3231
run: |
@@ -37,13 +36,13 @@ jobs:
3736
ninja-build \
3837
nasm
3938
40-
- name: Setup Gradle
41-
uses: gradle/actions/setup-gradle@v3
39+
- name: Set up Gradle Cache and Environment
40+
uses: gradle/actions/setup-gradle@0723195856401067f7a2779048b490ace7a47d7c # v5.0.2
4241

43-
- name: Setup cmake
44-
uses: jwlawson/actions-setup-cmake@v1.14
42+
- name: Set up CMake
43+
uses: jwlawson/actions-setup-cmake@0d6a7d60b009d01c9e7523be22153ff8f19460d3 # v2.2.0
4544
with:
4645
cmake-version: '3.22.1'
4746

48-
- name: Build app
49-
run: ./gradlew assemble
47+
- name: Build Check
48+
run: ./gradlew publishToMavenLocal

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@
88
.externalNativeBuild
99
.cxx
1010
local.properties
11+
/.kotlin

build.gradle

Lines changed: 0 additions & 26 deletions
This file was deleted.

build.gradle.kts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
buildscript {
2+
dependencies {
3+
classpath(libs.kotlin.gradle)
4+
}
5+
}
6+
7+
plugins {
8+
alias(libs.plugins.android.library) apply false
9+
alias(libs.plugins.tapmoc) apply false
10+
}

gradle/libs.versions.toml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
[versions]
2+
android-gradle = "9.2.0"
3+
kotlin-gradle = "2.3.21"
4+
maven-publish = "0.36.0"
5+
tapmoc = "0.4.2"
6+
7+
[libraries]
8+
kotlin-gradle = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", version.ref = "kotlin-gradle" }
9+
10+
[plugins]
11+
android-library = { id = "com.android.library", version.ref = "android-gradle" }
12+
maven-publish = { id = "com.vanniktech.maven.publish", version.ref = "maven-publish" }
13+
tapmoc = { id = "com.gradleup.tapmoc", version.ref = "tapmoc" }

gradle/wrapper/gradle-wrapper.jar

5.36 KB
Binary file not shown.
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-bin.zip
3+
distributionSha256Sum=2ab2958f2a1e51120c326cad6f385153bb11ee93b3c216c5fccebfdfbb7ec6cb
4+
distributionUrl=https\://services.gradle.org/distributions/gradle-9.4.1-bin.zip
45
zipStoreBase=GRADLE_USER_HOME
56
zipStorePath=wrapper/dists

0 commit comments

Comments
 (0)