Compare commits
9 commits
feature/ed
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| dd56377624 | |||
| 472b6da88e | |||
| dc3f3f5ac3 | |||
| 1180d3cfdd | |||
| ea7cadde4e | |||
| 817e8198b5 | |||
| 5f0fb91b49 | |||
| b0824407b1 | |||
| 19cc005d60 |
3 changed files with 20 additions and 14 deletions
|
|
@ -26,12 +26,6 @@ jobs:
|
||||||
- name: Grant execute permission to gradlew
|
- name: Grant execute permission to gradlew
|
||||||
run: chmod +x ./gradlew
|
run: chmod +x ./gradlew
|
||||||
|
|
||||||
- name: Monkeypatch version number
|
|
||||||
run: |
|
|
||||||
echo "--- @capacitor ---"
|
|
||||||
ls @capacitor
|
|
||||||
sed "s/\.\.\/node_modules\///" -i capacitor.settings.gradle
|
|
||||||
|
|
||||||
- name: Build signed APK
|
- name: Build signed APK
|
||||||
run: |
|
run: |
|
||||||
./gradlew --version
|
./gradlew --version
|
||||||
|
|
@ -44,18 +38,21 @@ jobs:
|
||||||
export keyPassword=${{ secrets.KEY_PASSWORD }}
|
export keyPassword=${{ secrets.KEY_PASSWORD }}
|
||||||
./gradlew build
|
./gradlew build
|
||||||
./gradlew assembleRelease
|
./gradlew assembleRelease
|
||||||
rm -rf app/build/outputs/apk/release/baselineProfiles
|
|
||||||
rm -rf app/build/outputs/apk/release/output-metadata.json
|
|
||||||
TAG=$( echo ${{ env.GITHUB_REF_NAME }} )
|
TAG=$( echo ${{ env.GITHUB_REF_NAME }} )
|
||||||
scp app/build/outputs/apk/release/app-release.apk hetzner:~/public/apk/mapcomplete-$TAG.apk
|
scp app/build/outputs/apk/release/app-release.apk hetzner:~/public/apk/mapcomplete-$TAG.apk
|
||||||
ssh hetzner 'rm -f public/apk/mapcomplete-latest.apk && cp "public/apk/$(ls -v public/apk/ | tail -n 1)" public/apk/mapcomplete-latest.apk'
|
ssh hetzner 'rm -f public/apk/mapcomplete-latest.apk && cp "public/apk/$(ls -v public/apk/ | tail -n 1)" public/apk/mapcomplete-latest.apk'
|
||||||
# Build versions vor legacy
|
# Build versions for legacy versions
|
||||||
./scripts/compile_version.shs $TAG 9-PIE 28
|
./scripts/compile_version.sh $TAG 9-PIE 28
|
||||||
./scripts/compile_version.sh $TAG 10-QUINCE-TART 29
|
./scripts/compile_version.sh $TAG 10-QUINCE-TART 29
|
||||||
./scripts/compile_version.sh $TAG 11-RED-VELVET-CAKE 30
|
./scripts/compile_version.sh $TAG 11-RED-VELVET-CAKE 30
|
||||||
./scripts/compile_version.sh $TAG 12-SNOW-CONE 31
|
./scripts/compile_version.sh $TAG 12-SNOW-CONE 31
|
||||||
./scripts/compile_version.sh $TAG 13-TIRAMISU 32
|
./scripts/compile_version.sh $TAG 13-TIRAMISU 32
|
||||||
|
|
||||||
|
- name: clean intermediate files
|
||||||
|
run: |
|
||||||
|
rm -rf app/build/outputs/apk/release/baselineProfiles
|
||||||
|
rm -rf app/build/outputs/apk/release/output-metadata.json
|
||||||
|
|
||||||
- name: Upload APK to forgejo releases (MapComplete)
|
- name: Upload APK to forgejo releases (MapComplete)
|
||||||
uses: https://source.mapcomplete.org/actions/forgejo-release@v2.6.0
|
uses: https://source.mapcomplete.org/actions/forgejo-release@v2.6.0
|
||||||
with:
|
with:
|
||||||
|
|
|
||||||
|
|
@ -5,9 +5,9 @@ android {
|
||||||
compileSdk rootProject.ext.compileSdkVersion
|
compileSdk rootProject.ext.compileSdkVersion
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "org.mapcomplete"
|
applicationId "org.mapcomplete"
|
||||||
minSdk 33
|
minSdk 28 // Use 32 for google play, 28 for FDroid
|
||||||
targetSdkVersion targetSdkVersion
|
targetSdkVersion 35
|
||||||
versionCode 9
|
versionCode 2031
|
||||||
versionName "debug"
|
versionName "debug"
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
aaptOptions {
|
aaptOptions {
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ import androidx.core.view.WindowCompat;
|
||||||
import com.getcapacitor.BridgeActivity;
|
import com.getcapacitor.BridgeActivity;
|
||||||
import com.getcapacitor.JSObject;
|
import com.getcapacitor.JSObject;
|
||||||
import com.getcapacitor.PluginCall;
|
import com.getcapacitor.PluginCall;
|
||||||
|
import android.app.Activity;
|
||||||
public class MainActivity extends BridgeActivity {
|
public class MainActivity extends BridgeActivity {
|
||||||
|
|
||||||
private PluginCall locationRequest = null;
|
private PluginCall locationRequest = null;
|
||||||
|
|
@ -67,6 +67,11 @@ public class MainActivity extends BridgeActivity {
|
||||||
responder.setKeepAlive(true);
|
responder.setKeepAlive(true);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Databridge.addResponder("exit", responder -> {
|
||||||
|
Log.i("databridge","got exit request");
|
||||||
|
finishAffinity();
|
||||||
|
});
|
||||||
|
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
EdgeToEdge.enable(this);
|
EdgeToEdge.enable(this);
|
||||||
|
|
||||||
|
|
@ -86,6 +91,10 @@ public class MainActivity extends BridgeActivity {
|
||||||
});
|
});
|
||||||
}else{
|
}else{
|
||||||
Log.i("insets","Not enabling insets, version to low");
|
Log.i("insets","Not enabling insets, version to low");
|
||||||
|
Databridge.addResponder("insets", (responder) -> {
|
||||||
|
var json = "{ \"top\": 0, \"bottom\": 0}";
|
||||||
|
Databridge.sendAnswerTo(responder, json);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue