mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-28 00:43:38 +00:00
Organic Maps sources as of 02.04.2025 (fad26bbf22ac3da75e01e62aa01e5c8e11861005)
To expand with full Organic Maps and Maps.ME commits history run: git remote add om-historic [om-historic.git repo url] git fetch --tags om-historic git replace squashed-history historic-commits
This commit is contained in:
121
.github/workflows/android-check.yaml
vendored
Normal file
121
.github/workflows/android-check.yaml
vendored
Normal file
@@ -0,0 +1,121 @@
|
||||
name: Android Check
|
||||
on:
|
||||
workflow_dispatch: # Manual trigger
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
pull_request:
|
||||
paths-ignore:
|
||||
- .gitignore
|
||||
- .github/**
|
||||
- '!.github/workflows/android-check.yaml' # Run check on self change
|
||||
- '**/*_tests/**'
|
||||
- CONTRIBUTORS
|
||||
- LICENSE
|
||||
- NOTICE
|
||||
- README.md
|
||||
- android/app/src/fdroid/**
|
||||
- android/app/src/google/**
|
||||
- iphone/**
|
||||
- data/strings/**
|
||||
- docs/**
|
||||
- generator/**
|
||||
- packaging/**
|
||||
- platform/*apple*
|
||||
- platform/*_ios*
|
||||
- platform/*_linux*
|
||||
- platform/*_mac*
|
||||
- platform/*qt*
|
||||
- platform/*_win*
|
||||
- pyhelpers/**
|
||||
- qt*/**
|
||||
- skin_generator/**
|
||||
- tools/**
|
||||
- track_generator/**
|
||||
- xcode/**
|
||||
|
||||
env:
|
||||
JAVA_HOME: /usr/lib/jvm/temurin-17-jdk-amd64 # Java 17 is required for Android Gradle 8 plugin
|
||||
|
||||
jobs:
|
||||
lint:
|
||||
name: Android Lint
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 1
|
||||
|
||||
- name: Parallel submodules checkout
|
||||
shell: bash
|
||||
run: git submodule update --depth 1 --init --recursive --jobs=$(($(nproc) * 20))
|
||||
|
||||
- name: Configure repository
|
||||
shell: bash
|
||||
run: ./configure.sh
|
||||
|
||||
- name: Lint
|
||||
shell: bash
|
||||
working-directory: android
|
||||
run: ./gradlew -Pandroidauto=true lint
|
||||
|
||||
android-check:
|
||||
name: Build Android Debug
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
flavor: [WebDebug, FdroidDebug]
|
||||
include:
|
||||
- flavor: WebDebug
|
||||
arch: arm64
|
||||
- flavor: FdroidDebug
|
||||
arch: arm32
|
||||
# Cancels previous jobs if the same branch or PR was updated again.
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ matrix.flavor }}-${{ github.event.pull_request.number || github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
steps:
|
||||
- name: Install build tools and dependencies
|
||||
shell: bash
|
||||
run: |
|
||||
sudo apt-get update -y
|
||||
sudo apt-get install -y ninja-build
|
||||
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 200 # enough to get all commits for the current day
|
||||
|
||||
- name: Parallel submodules checkout
|
||||
shell: bash
|
||||
run: git submodule update --depth 1 --init --recursive --jobs=$(($(nproc) * 20))
|
||||
|
||||
- name: Configure repository
|
||||
shell: bash
|
||||
run: ./configure.sh
|
||||
|
||||
- name: Configure ccache
|
||||
uses: hendrikmuhs/ccache-action@v1.2
|
||||
with:
|
||||
key: ${{ github.workflow }}-${{ matrix.flavor }}
|
||||
|
||||
- name: Compile ${{ matrix.flavor }}
|
||||
shell: bash
|
||||
working-directory: android
|
||||
env:
|
||||
CMAKE_C_COMPILER_LAUNCHER: ccache
|
||||
CMAKE_CXX_COMPILER_LAUNCHER: ccache
|
||||
run: |
|
||||
cmake --version
|
||||
ninja --version
|
||||
./gradlew -P${{ matrix.arch }} assemble${{ matrix.flavor }}
|
||||
|
||||
- name: Upload ${{ matrix.flavor }} apk
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: android-${{ matrix.flavor }}
|
||||
path: android/app/build/outputs/apk/**/OrganicMaps-*.apk
|
||||
if-no-files-found: error
|
||||
Reference in New Issue
Block a user