You've already forked android-client
mirror of
https://github.com/netbirdio/android-client.git
synced 2026-05-22 17:10:49 -07:00
f81f81ce6e
Rewrite the client in native Java. There were no new features added in this change, but that's the first step in moving to a faster development cycle for NetBird client.
55 lines
1.7 KiB
YAML
55 lines
1.7 KiB
YAML
name: build debug
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v3
|
|
with:
|
|
submodules: recursive
|
|
- name: Setup Java
|
|
uses: actions/setup-java@v3
|
|
with:
|
|
java-version: "17"
|
|
distribution: "adopt"
|
|
cache: "gradle"
|
|
- name: Install Go
|
|
uses: actions/setup-go@v4
|
|
with:
|
|
go-version: "1.23.3"
|
|
- name: Setup Android SDK
|
|
uses: android-actions/setup-android@v3
|
|
with:
|
|
cmdline-tools-version: 12266719
|
|
- name: NDK Cache
|
|
id: ndk-cache
|
|
uses: actions/cache@v3
|
|
with:
|
|
path: /usr/local/lib/android/sdk/ndk
|
|
key: ndk-cache-23.1.7779620
|
|
- name: Setup NDK
|
|
run: /usr/local/lib/android/sdk/cmdline-tools/16.0/bin/sdkmanager --install "ndk;23.1.7779620"
|
|
- name: Install gomobile
|
|
run: go install golang.org/x/mobile/cmd/gomobile@v0.0.0-20230531173138-3c911d8e3eda
|
|
- name: Build NetBird Go library
|
|
run: PATH=$PATH:$(go env GOPATH)/bin bash -x build-android-lib.sh
|
|
env:
|
|
ANDROID_NDK_HOME: /usr/local/lib/android/sdk/ndk/23.1.7779620
|
|
- name: Get short Git hash
|
|
run: echo "SHORT_GIT_SHA=$(git rev-parse --short HEAD)" >> $GITHUB_ENV
|
|
- name: Build debug apk
|
|
run: ./gradlew --no-daemon assembleDebug -PversionName="ci-${SHORT_GIT_SHA}"
|
|
- name: Upload non tags for debug purposes
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: debug-apk
|
|
path: app/build/outputs/apk/debug/app-debug.apk
|
|
retention-days: 1
|