diff options
author | Daniel Lublin <daniel@lublin.se> | 2020-04-20 16:38:45 +0300 |
---|---|---|
committer | Daniel Lublin <daniel@lublin.se> | 2020-04-20 22:44:48 +0300 |
commit | 5ac8b69518bd6f158c69f8686a59513396294b35 (patch) | |
tree | 8fa1d32bcb0805c2e1c06ae04dd0af1f2158b0fd | |
parent | 1ca410c0964172a3ab566868c581f2f33f093474 (diff) |
Add beta flavour, and allow for overriding signing
Removing jenkins and free flavor.
29 files changed, 168 insertions, 220 deletions
diff --git a/app/build.gradle b/app/build.gradle index 773fff6..e7676a9 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -38,20 +38,19 @@ repositories { google() } -dependencies { - implementation 'androidx.multidex:multidex:2.0.1' - implementation project(":libraries:humla") - implementation 'androidx.appcompat:appcompat:1.1.0' - implementation 'androidx.cardview:cardview:1.0.0' - implementation 'androidx.recyclerview:recyclerview:1.1.0' - implementation 'org.jsoup:jsoup:1.13.1' - implementation 'info.guardianproject.netcipher:netcipher:2.1.0' +def gitDescribe = { -> + def stdout = new ByteArrayOutputStream() + exec { + commandLine "git", "describe", "--tags", "--always" + standardOutput = stdout + } + return stdout.toString().trim() } - -// Keep my credentials private :^) def signingFile = file 'signing.gradle' -if (signingFile.exists()) apply from: 'signing.gradle' +if (signingFile.exists()) apply from: signingFile +def signingBetaFile = file 'signing-beta.gradle' +if (signingBetaFile.exists()) apply from: signingBetaFile android { compileSdkVersion 29 @@ -64,45 +63,54 @@ android { applicationId "se.lublin.mumla" versionCode 80 - versionName "3.5.0-beta2" + versionName gitDescribe() setProperty("archivesBaseName", "mumla") testInstrumentationRunner "android.test.InstrumentationTestRunner" - buildConfigField "boolean", "DONATE_NAG", "false" + } + + flavorDimensions "release" + productFlavors { + official { + dimension "release" + applicationId "se.lublin.mumla" + } + beta { + dimension "release" + applicationId "se.lublin.mumla.beta" + } } buildTypes { + // signingConfig beta will override release { - if (signingFile.exists()) signingConfig signingConfigs.release + if (android.hasProperty("signingConfigs")) { + if (signingConfigs.hasProperty("release")) { + signingConfig signingConfigs.release + } + if (signingConfigs.hasProperty("beta")) { + signingConfig signingConfigs.beta + } + } } debug { + versionNameSuffix "-debug" + if (android.hasProperty("signingConfigs")) { + if (signingConfigs.hasProperty("beta")) { + signingConfig signingConfigs.beta + } + } } } - flavorDimensions "version" - productFlavors { - official { - dimension "version" - applicationId "se.lublin.mumla" - } - free { - dimension "version" - applicationId "se.lublin.mumla.free" - buildConfigField "boolean", "DONATE_NAG", "true" - } - jenkins { - dimension "version" - // Abuse Jenkins environment variables. Neat. - def env = System.getenv() - if (env.containsKey("BUILD_NUMBER") && env.containsKey("BUILD_DISPLAY_NAME")) { - versionCode Integer.parseInt(env.get("BUILD_NUMBER")) - versionName env.get("BUILD_DISPLAY_NAME") - } else { - versionCode 1 - versionName "Unknown Nightly" + // betas may be released every minute + // TODO? dynamic stuff, have to rebuild a lot + applicationVariants.all { variant -> + if (variant.flavorName == "beta") { + variant.outputs.each { output -> + output.versionCodeOverride = System.currentTimeSeconds() / 60 } - applicationId "se.lublin.mumla.jenkins" } } @@ -119,3 +127,13 @@ android { explainIssues true } } + +dependencies { + implementation 'androidx.multidex:multidex:2.0.1' + implementation project(":libraries:humla") + implementation 'androidx.appcompat:appcompat:1.1.0' + implementation 'androidx.cardview:cardview:1.0.0' + implementation 'androidx.recyclerview:recyclerview:1.1.0' + implementation 'org.jsoup:jsoup:1.13.1' + implementation 'info.guardianproject.netcipher:netcipher:2.1.0' +} diff --git a/app/src/beta/AndroidManifest.xml b/app/src/beta/AndroidManifest.xml new file mode 100644 index 0000000..56bb214 --- /dev/null +++ b/app/src/beta/AndroidManifest.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="utf-8"?> +<manifest xmlns:android="http://schemas.android.com/apk/res/android"> + <application> + <provider + android:name="se.lublin.mumla.channel.ChannelSearchProvider" + android:authorities="se.lublin.mumla.beta.channel.ChannelSearchProvider" + android:exported="false" /> + </application> +</manifest> diff --git a/app/src/beta/ic_launcher-playstore.png b/app/src/beta/ic_launcher-playstore.png Binary files differnew file mode 100644 index 0000000..175259b --- /dev/null +++ b/app/src/beta/ic_launcher-playstore.png diff --git a/app/src/beta/res/drawable/ic_launcher_foreground.xml b/app/src/beta/res/drawable/ic_launcher_foreground.xml new file mode 100644 index 0000000..7d35989 --- /dev/null +++ b/app/src/beta/res/drawable/ic_launcher_foreground.xml @@ -0,0 +1,37 @@ +<vector xmlns:android="http://schemas.android.com/apk/res/android" + android:width="108dp" + android:height="108dp" + android:viewportWidth="328.55615" + android:viewportHeight="328.55615"> + <group android:translateX="68.278076" + android:translateY="68.278076"> + <path + android:pathData="m96,101h59c2,0 2,0 2,2.1 0,1.5 0.2,3 -0.1,4.4 -0.2,1.3 -0.7,2.6 -1.3,3.8 -1,1.8 -2.1,3.5 -3.2,5.2 -0.8,1.2 -1.7,2.4 -2.6,3.5 -1.3,1.6 -2.4,3.2 -3.9,4.6 -2,1.8 -4.1,3.5 -6.3,5 -2,1.3 -4,2.5 -6.2,3.6 -3.5,1.7 -7.2,2.4 -11.1,2.4 -2.6,0 -5.2,0.1 -7.7,-0.3 -3.3,-0.5 -6.6,-1.2 -9.5,-3 -0.5,-0.3 -0.8,-1.1 -0.8,-1.7 -0.2,-3.6 -2.7,-6.8 -6.3,-7.8 -3.3,-0.9 -6.8,0.7 -8.3,4 -0.4,0.9 -1,1.8 -1.3,2.8 -1,4 3.7,10.1 7.7,9.9 0.9,-0.1 2,-0.3 2.8,-0.7 2,-1.2 3.7,-0.8 5.7,0 2.4,1 4.9,1.8 7.5,2.3 3,0.6 6.1,1.2 9.2,1.2 2.2,0.1 4.4,-0.6 6.6,-1.1 2.6,-0.7 5.2,-1.4 7.8,-2.4 1.6,-0.6 3,-1.6 4.4,-2.5 4.2,-2.5 7.7,-5.9 11,-9.5 1.738,-1.917 4.025,-5.841 6.092,-4.967 0.007,9.81 0.009,18.993 0.008,27.967 0,0.7 -0.4,1.6 -1,2.1 -6.2,5.1 -13.1,9.3 -20.4,12.7 -7,3.2 -14.3,5.5 -21.9,6.9 -9,1.7 -18,2.2 -27.1,1.3 -9,-0.9 -17.7,-2.9 -26.2,-6.3 -6.6,-2.6 -12.9,-6 -18.8,-9.8 -2.2,-1.4 -4.2,-3.1 -6.3,-4.7 -0.4,-0.4 -0.7,-1.1 -0.7,-1.7 0.05,-30.991 -0.027,-36.4 0,-46.9 -0.09,-2.198 0,-2.2 2.1,-2.2C56.8,101 76.4,101 96,101Z" + android:fillColor="#ffffff" + android:fillAlpha="1"/> + <path + android:pathData="M96,94.5c-19.6,0 -39.2,0 -58.9,0c-2.1,0 -2.2,0 -2,-2.2c0.3,-3.3 0.3,-6.6 1.1,-9.8c1,-4 2.6,-8 4.1,-11.8c3.2,-7.9 8.5,-14.4 14.8,-20.1c2.3,-2.1 4.9,-3.8 7.4,-5.6c0.9,-0.6 1,-1.2 0.5,-2.1c-2.8,-5.4 -5.6,-10.8 -8.4,-16.2c-1.6,-3.1 -1.1,-5.7 1.6,-7.5c1.8,-1.2 4.6,-0.8 5.7,1.1c2.2,4 4.3,8 6.5,12c1.1,2 2.1,4.1 3.2,6.2c0.4,0.9 1,1.2 2,0.8c2.6,-0.9 5.3,-1.9 7.9,-2.6c2.2,-0.6 4.5,-0.9 6.8,-1.2c2.7,-0.3 5.4,-0.7 8.1,-0.6c3.7,0.2 7.4,0.5 11,1.2c3.5,0.7 6.9,1.8 10.3,2.8c1.9,0.6 2.2,0.7 3.1,-1.1c2.8,-5.3 5.4,-10.7 8.2,-16c0.8,-1.5 1.6,-3 3.5,-3.3c1.9,-0.4 3.5,0 4.8,1.6c1.2,1.6 1.5,3.5 0.7,5.3c-1.9,3.9 -4,7.8 -6,11.6c-0.9,1.8 -1.8,3.6 -2.9,5.3c-0.7,1.1 -0.6,1.9 0.6,2.6c4.6,2.9 8.6,6.5 12.2,10.5c4.5,5 8.2,10.4 10.5,16.7c1.2,3.3 2.6,6.5 3.4,9.9c0.8,3.6 0.9,7.4 1.3,11.1c0.1,0.8 -0.3,1.2 -1.2,1.2c-0.3,0 -0.6,0 -0.9,0C135.3,94.5 115.7,94.5 96,94.5zM68.1,72c3.1,0 5.6,-2.6 5.6,-5.8c0,-3.2 -2.7,-6.2 -5.8,-6.1c-3.2,0.1 -5.2,2.9 -5.3,6.2C62.5,69.1 65,72.3 68.1,72zM124,72c3.1,0.4 5.6,-2.8 5.5,-5.7c-0.1,-3.3 -2.1,-6 -5.3,-6.2c-3,-0.1 -5.8,2.8 -5.8,6.1C118.4,69.4 120.9,72 124,72z" + android:fillColor="#ffffff" + android:fillAlpha="1"/> + <path + android:pathData="m12.3,96.1c0.3,-10.8 4.4,-18.9 13.1,-24.4 3,-1.9 6.4,-2.8 9.9,-3.3 1.3,-0.2 1.6,0.2 1.2,1.5 -0.8,2.4 -2,4.7 -2.6,7.2 -1,4.2 -2.2,8.5 -2.4,12.9 -0.5,9.6 -0.3,19.3 -0.5,28.9 0,2.3 -0.1,2.4 -2.3,1.5 -8.4,-3.6 -13.6,-9.9 -15.6,-18.8 -0.5,-2 -0.6,-4.1 -0.8,-5.5z" + android:fillColor="#ffffff" + android:fillAlpha="1"/> + <path + android:pathData="m160.8,88.4c-0.2,-3.4 -1,-6.8 -1.8,-10.2 -0.7,-2.9 -1.7,-5.7 -2.7,-8.6 -0.4,-1.2 0,-1.4 1.1,-1.3 4.5,0.4 8.6,2.1 12.1,4.9 7,5.7 10.4,13.1 10.2,22.2 -0.2,8.6 -3.6,15.7 -10.3,21 -2,1.6 -4.4,2.5 -6.7,3.7 -1,0.5 -1.6,0.1 -1.6,-1.2v-12.3c0.136,-5.467 0.025,-13.015 -0.3,-18.2z" + android:fillColor="#ffffff" + android:fillAlpha="1"/> + <path + android:pathData="m66.208,73.286c-1.11,-0.299 -1.955,-0.845 -2.945,-1.904 -1.426,-1.524 -1.979,-2.935 -1.978,-5.046 0.001,-3.142 1.518,-5.821 4.023,-7.105 0.878,-0.45 1.199,-0.513 2.636,-0.513 1.442,0 1.765,0.063 2.727,0.535 2.953,1.448 4.842,5.028 4.293,8.139 -0.541,3.072 -2.788,5.397 -5.743,5.943 -1.329,0.246 -1.957,0.235 -3.013,-0.05z" + android:strokeWidth="0.18178086" + android:fillColor="#d32f2f" + android:fillType="nonZero" + android:fillAlpha="1"/> + <path + android:pathData="m122.757,73.346c-3.691,-0.772 -6.132,-4.347 -5.612,-8.22 0.318,-2.37 2.092,-4.816 4.268,-5.884 0.919,-0.451 1.275,-0.522 2.613,-0.522 1.384,0 1.678,0.064 2.762,0.597 2.092,1.03 3.332,2.811 3.901,5.603 0.493,2.415 -0.143,4.692 -1.831,6.56 -1.517,1.679 -3.743,2.359 -6.1,1.866z" + android:strokeWidth="0.18177266" + android:fillColor="#d32f2f" + android:fillType="nonZero" + android:fillAlpha="1"/> + </group> +</vector> diff --git a/app/src/beta/res/drawable/ic_mumla.xml b/app/src/beta/res/drawable/ic_mumla.xml new file mode 100644 index 0000000..3f4a15b --- /dev/null +++ b/app/src/beta/res/drawable/ic_mumla.xml @@ -0,0 +1,34 @@ +<vector xmlns:android="http://schemas.android.com/apk/res/android" + android:width="192dp" + android:height="192dp" + android:viewportWidth="192" + android:viewportHeight="192"> + <path + android:pathData="m96,101h59c2,0 2,0 2,2.1 0,1.5 0.2,3 -0.1,4.4 -0.2,1.3 -0.7,2.6 -1.3,3.8 -1,1.8 -2.1,3.5 -3.2,5.2 -0.8,1.2 -1.7,2.4 -2.6,3.5 -1.3,1.6 -2.4,3.2 -3.9,4.6 -2,1.8 -4.1,3.5 -6.3,5 -2,1.3 -4,2.5 -6.2,3.6 -3.5,1.7 -7.2,2.4 -11.1,2.4 -2.6,0 -5.2,0.1 -7.7,-0.3 -3.3,-0.5 -6.6,-1.2 -9.5,-3 -0.5,-0.3 -0.8,-1.1 -0.8,-1.7 -0.2,-3.6 -2.7,-6.8 -6.3,-7.8 -3.3,-0.9 -6.8,0.7 -8.3,4 -0.4,0.9 -1,1.8 -1.3,2.8 -1,4 3.7,10.1 7.7,9.9 0.9,-0.1 2,-0.3 2.8,-0.7 2,-1.2 3.7,-0.8 5.7,0 2.4,1 4.9,1.8 7.5,2.3 3,0.6 6.1,1.2 9.2,1.2 2.2,0.1 4.4,-0.6 6.6,-1.1 2.6,-0.7 5.2,-1.4 7.8,-2.4 1.6,-0.6 3,-1.6 4.4,-2.5 4.2,-2.5 7.7,-5.9 11,-9.5 1.738,-1.917 4.025,-5.841 6.092,-4.967 0.007,9.81 0.009,18.993 0.008,27.967 0,0.7 -0.4,1.6 -1,2.1 -6.2,5.1 -13.1,9.3 -20.4,12.7 -7,3.2 -14.3,5.5 -21.9,6.9 -9,1.7 -18,2.2 -27.1,1.3 -9,-0.9 -17.7,-2.9 -26.2,-6.3 -6.6,-2.6 -12.9,-6 -18.8,-9.8 -2.2,-1.4 -4.2,-3.1 -6.3,-4.7 -0.4,-0.4 -0.7,-1.1 -0.7,-1.7 0.05,-30.991 -0.027,-36.4 0,-46.9 -0.09,-2.198 0,-2.2 2.1,-2.2C56.8,101 76.4,101 96,101Z" + android:fillColor="#ffffff" + android:fillAlpha="1"/> + <path + android:pathData="M96,94.5c-19.6,0 -39.2,0 -58.9,0c-2.1,0 -2.2,0 -2,-2.2c0.3,-3.3 0.3,-6.6 1.1,-9.8c1,-4 2.6,-8 4.1,-11.8c3.2,-7.9 8.5,-14.4 14.8,-20.1c2.3,-2.1 4.9,-3.8 7.4,-5.6c0.9,-0.6 1,-1.2 0.5,-2.1c-2.8,-5.4 -5.6,-10.8 -8.4,-16.2c-1.6,-3.1 -1.1,-5.7 1.6,-7.5c1.8,-1.2 4.6,-0.8 5.7,1.1c2.2,4 4.3,8 6.5,12c1.1,2 2.1,4.1 3.2,6.2c0.4,0.9 1,1.2 2,0.8c2.6,-0.9 5.3,-1.9 7.9,-2.6c2.2,-0.6 4.5,-0.9 6.8,-1.2c2.7,-0.3 5.4,-0.7 8.1,-0.6c3.7,0.2 7.4,0.5 11,1.2c3.5,0.7 6.9,1.8 10.3,2.8c1.9,0.6 2.2,0.7 3.1,-1.1c2.8,-5.3 5.4,-10.7 8.2,-16c0.8,-1.5 1.6,-3 3.5,-3.3c1.9,-0.4 3.5,0 4.8,1.6c1.2,1.6 1.5,3.5 0.7,5.3c-1.9,3.9 -4,7.8 -6,11.6c-0.9,1.8 -1.8,3.6 -2.9,5.3c-0.7,1.1 -0.6,1.9 0.6,2.6c4.6,2.9 8.6,6.5 12.2,10.5c4.5,5 8.2,10.4 10.5,16.7c1.2,3.3 2.6,6.5 3.4,9.9c0.8,3.6 0.9,7.4 1.3,11.1c0.1,0.8 -0.3,1.2 -1.2,1.2c-0.3,0 -0.6,0 -0.9,0C135.3,94.5 115.7,94.5 96,94.5zM68.1,72c3.1,0 5.6,-2.6 5.6,-5.8c0,-3.2 -2.7,-6.2 -5.8,-6.1c-3.2,0.1 -5.2,2.9 -5.3,6.2C62.5,69.1 65,72.3 68.1,72zM124,72c3.1,0.4 5.6,-2.8 5.5,-5.7c-0.1,-3.3 -2.1,-6 -5.3,-6.2c-3,-0.1 -5.8,2.8 -5.8,6.1C118.4,69.4 120.9,72 124,72z" + android:fillColor="#ffffff" + android:fillAlpha="1"/> + <path + android:pathData="m12.3,96.1c0.3,-10.8 4.4,-18.9 13.1,-24.4 3,-1.9 6.4,-2.8 9.9,-3.3 1.3,-0.2 1.6,0.2 1.2,1.5 -0.8,2.4 -2,4.7 -2.6,7.2 -1,4.2 -2.2,8.5 -2.4,12.9 -0.5,9.6 -0.3,19.3 -0.5,28.9 0,2.3 -0.1,2.4 -2.3,1.5 -8.4,-3.6 -13.6,-9.9 -15.6,-18.8 -0.5,-2 -0.6,-4.1 -0.8,-5.5z" + android:fillColor="#ffffff" + android:fillAlpha="1"/> + <path + android:pathData="m160.8,88.4c-0.2,-3.4 -1,-6.8 -1.8,-10.2 -0.7,-2.9 -1.7,-5.7 -2.7,-8.6 -0.4,-1.2 0,-1.4 1.1,-1.3 4.5,0.4 8.6,2.1 12.1,4.9 7,5.7 10.4,13.1 10.2,22.2 -0.2,8.6 -3.6,15.7 -10.3,21 -2,1.6 -4.4,2.5 -6.7,3.7 -1,0.5 -1.6,0.1 -1.6,-1.2v-12.3c0.136,-5.467 0.025,-13.015 -0.3,-18.2z" + android:fillColor="#ffffff" + android:fillAlpha="1"/> + <path + android:pathData="m66.208,73.286c-1.11,-0.299 -1.955,-0.845 -2.945,-1.904 -1.426,-1.524 -1.979,-2.935 -1.978,-5.046 0.001,-3.142 1.518,-5.821 4.023,-7.105 0.878,-0.45 1.199,-0.513 2.636,-0.513 1.442,0 1.765,0.063 2.727,0.535 2.953,1.448 4.842,5.028 4.293,8.139 -0.541,3.072 -2.788,5.397 -5.743,5.943 -1.329,0.246 -1.957,0.235 -3.013,-0.05z" + android:strokeWidth="0.18178086" + android:fillColor="#d32f2f" + android:fillType="nonZero" + android:fillAlpha="1"/> + <path + android:pathData="m122.757,73.346c-3.691,-0.772 -6.132,-4.347 -5.612,-8.22 0.318,-2.37 2.092,-4.816 4.268,-5.884 0.919,-0.451 1.275,-0.522 2.613,-0.522 1.384,0 1.678,0.064 2.762,0.597 2.092,1.03 3.332,2.811 3.901,5.603 0.493,2.415 -0.143,4.692 -1.831,6.56 -1.517,1.679 -3.743,2.359 -6.1,1.866z" + android:strokeWidth="0.18177266" + android:fillColor="#d32f2f" + android:fillType="nonZero" + android:fillAlpha="1"/> +</vector> diff --git a/app/src/beta/res/mipmap-anydpi-v26/ic_launcher.xml b/app/src/beta/res/mipmap-anydpi-v26/ic_launcher.xml new file mode 100644 index 0000000..7353dbd --- /dev/null +++ b/app/src/beta/res/mipmap-anydpi-v26/ic_launcher.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8"?> +<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android"> + <background android:drawable="@color/ic_launcher_background"/> + <foreground android:drawable="@drawable/ic_launcher_foreground"/> +</adaptive-icon>
\ No newline at end of file diff --git a/app/src/beta/res/mipmap-anydpi-v26/ic_launcher_round.xml b/app/src/beta/res/mipmap-anydpi-v26/ic_launcher_round.xml new file mode 100644 index 0000000..7353dbd --- /dev/null +++ b/app/src/beta/res/mipmap-anydpi-v26/ic_launcher_round.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8"?> +<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android"> + <background android:drawable="@color/ic_launcher_background"/> + <foreground android:drawable="@drawable/ic_launcher_foreground"/> +</adaptive-icon>
\ No newline at end of file diff --git a/app/src/beta/res/mipmap-hdpi/ic_launcher.png b/app/src/beta/res/mipmap-hdpi/ic_launcher.png Binary files differnew file mode 100644 index 0000000..c58bf26 --- /dev/null +++ b/app/src/beta/res/mipmap-hdpi/ic_launcher.png diff --git a/app/src/beta/res/mipmap-hdpi/ic_launcher_round.png b/app/src/beta/res/mipmap-hdpi/ic_launcher_round.png Binary files differnew file mode 100644 index 0000000..dfc7ff7 --- /dev/null +++ b/app/src/beta/res/mipmap-hdpi/ic_launcher_round.png diff --git a/app/src/beta/res/mipmap-mdpi/ic_launcher.png b/app/src/beta/res/mipmap-mdpi/ic_launcher.png Binary files differnew file mode 100644 index 0000000..060e2ca --- /dev/null +++ b/app/src/beta/res/mipmap-mdpi/ic_launcher.png diff --git a/app/src/beta/res/mipmap-mdpi/ic_launcher_round.png b/app/src/beta/res/mipmap-mdpi/ic_launcher_round.png Binary files differnew file mode 100644 index 0000000..fee366f --- /dev/null +++ b/app/src/beta/res/mipmap-mdpi/ic_launcher_round.png diff --git a/app/src/beta/res/mipmap-xhdpi/ic_launcher.png b/app/src/beta/res/mipmap-xhdpi/ic_launcher.png Binary files differnew file mode 100644 index 0000000..3e969d0 --- /dev/null +++ b/app/src/beta/res/mipmap-xhdpi/ic_launcher.png diff --git a/app/src/beta/res/mipmap-xhdpi/ic_launcher_round.png b/app/src/beta/res/mipmap-xhdpi/ic_launcher_round.png Binary files differnew file mode 100644 index 0000000..859c26e --- /dev/null +++ b/app/src/beta/res/mipmap-xhdpi/ic_launcher_round.png diff --git a/app/src/beta/res/mipmap-xxhdpi/ic_launcher.png b/app/src/beta/res/mipmap-xxhdpi/ic_launcher.png Binary files differnew file mode 100644 index 0000000..115a1f2 --- /dev/null +++ b/app/src/beta/res/mipmap-xxhdpi/ic_launcher.png diff --git a/app/src/beta/res/mipmap-xxhdpi/ic_launcher_round.png b/app/src/beta/res/mipmap-xxhdpi/ic_launcher_round.png Binary files differnew file mode 100644 index 0000000..c86e0d3 --- /dev/null +++ b/app/src/beta/res/mipmap-xxhdpi/ic_launcher_round.png diff --git a/app/src/beta/res/mipmap-xxxhdpi/ic_launcher.png b/app/src/beta/res/mipmap-xxxhdpi/ic_launcher.png Binary files differnew file mode 100644 index 0000000..4bf5743 --- /dev/null +++ b/app/src/beta/res/mipmap-xxxhdpi/ic_launcher.png diff --git a/app/src/beta/res/mipmap-xxxhdpi/ic_launcher_round.png b/app/src/beta/res/mipmap-xxxhdpi/ic_launcher_round.png Binary files differnew file mode 100644 index 0000000..17fdfb1 --- /dev/null +++ b/app/src/beta/res/mipmap-xxxhdpi/ic_launcher_round.png diff --git a/app/src/beta/res/values/ic_launcher_background.xml b/app/src/beta/res/values/ic_launcher_background.xml new file mode 100644 index 0000000..907871c --- /dev/null +++ b/app/src/beta/res/values/ic_launcher_background.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<resources> + <color name="ic_launcher_background">#09194B</color> +</resources>
\ No newline at end of file diff --git a/app/src/beta/res/values/strings.xml b/app/src/beta/res/values/strings.xml new file mode 100644 index 0000000..9d6fae1 --- /dev/null +++ b/app/src/beta/res/values/strings.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<resources> + <string name="app_name">Mumla Beta</string> +</resources> diff --git a/app/src/beta/res/xml/searchable.xml b/app/src/beta/res/xml/searchable.xml new file mode 100644 index 0000000..47cbcaa --- /dev/null +++ b/app/src/beta/res/xml/searchable.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8"?> +<searchable xmlns:android="http://schemas.android.com/apk/res/android" + android:label="@string/app_name" + android:hint="@string/searchHint" + android:searchSuggestAuthority="se.lublin.mumla.nightly.channel.ChannelSearchProvider" + android:searchSuggestSelection=" ?" + android:searchSuggestThreshold="1" + android:searchSuggestIntentAction="android.intent.action.SEARCH" + android:inputType="textNoSuggestions" + android:imeOptions="actionNone"> +</searchable> diff --git a/app/src/free/AndroidManifest.xml b/app/src/free/AndroidManifest.xml deleted file mode 100644 index a94cec4..0000000 --- a/app/src/free/AndroidManifest.xml +++ /dev/null @@ -1,29 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> - -<!-- - ~ Copyright (C) 2014 Andrew Comminos - ~ - ~ This program is free software: you can redistribute it and/or modify - ~ it under the terms of the GNU General Public License as published by - ~ the Free Software Foundation, either version 3 of the License, or - ~ (at your option) any later version. - ~ - ~ This program is distributed in the hope that it will be useful, - ~ but WITHOUT ANY WARRANTY; without even the implied warranty of - ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - ~ GNU General Public License for more details. - ~ - ~ You should have received a copy of the GNU General Public License - ~ along with this program. If not, see <http://www.gnu.org/licenses/>. - --> - -<manifest xmlns:android="http://schemas.android.com/apk/res/android"> - - <application> - <provider - android:name="se.lublin.mumla.channel.ChannelSearchProvider" - android:authorities="se.lublin.mumla.free.channel.ChannelSearchProvider" - android:exported="false" /> - </application> - -</manifest> diff --git a/app/src/free/res/values/strings.xml b/app/src/free/res/values/strings.xml deleted file mode 100644 index bc3e969..0000000 --- a/app/src/free/res/values/strings.xml +++ /dev/null @@ -1,21 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- - ~ Copyright (C) 2014 Andrew Comminos - ~ - ~ This program is free software: you can redistribute it and/or modify - ~ it under the terms of the GNU General Public License as published by - ~ the Free Software Foundation, either version 3 of the License, or - ~ (at your option) any later version. - ~ - ~ This program is distributed in the hope that it will be useful, - ~ but WITHOUT ANY WARRANTY; without even the implied warranty of - ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - ~ GNU General Public License for more details. - ~ - ~ You should have received a copy of the GNU General Public License - ~ along with this program. If not, see <http://www.gnu.org/licenses/>. - --> - -<resources> - <string name="app_name">Mumla Free</string> -</resources>
\ No newline at end of file diff --git a/app/src/free/res/xml/searchable.xml b/app/src/free/res/xml/searchable.xml deleted file mode 100644 index 192b2df..0000000 --- a/app/src/free/res/xml/searchable.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- - ~ Copyright (C) 2014 Andrew Comminos - ~ - ~ This program is free software: you can redistribute it and/or modify - ~ it under the terms of the GNU General Public License as published by - ~ the Free Software Foundation, either version 3 of the License, or - ~ (at your option) any later version. - ~ - ~ This program is distributed in the hope that it will be useful, - ~ but WITHOUT ANY WARRANTY; without even the implied warranty of - ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - ~ GNU General Public License for more details. - ~ - ~ You should have received a copy of the GNU General Public License - ~ along with this program. If not, see <http://www.gnu.org/licenses/>. - --> - -<searchable xmlns:android="http://schemas.android.com/apk/res/android" - android:label="@string/app_name" - android:hint="@string/searchHint" - android:searchSuggestAuthority="se.lublin.mumla.free.channel.ChannelSearchProvider" - android:searchSuggestSelection=" ?" - android:searchSuggestThreshold="1" - android:searchSuggestIntentAction="android.intent.action.SEARCH" - android:inputType="textNoSuggestions" - android:imeOptions="actionNone"> -</searchable>
\ No newline at end of file diff --git a/app/src/jenkins/AndroidManifest.xml b/app/src/jenkins/AndroidManifest.xml deleted file mode 100644 index 2fadbf6..0000000 --- a/app/src/jenkins/AndroidManifest.xml +++ /dev/null @@ -1,29 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> - -<!-- - ~ Copyright (C) 2014 Andrew Comminos - ~ - ~ This program is free software: you can redistribute it and/or modify - ~ it under the terms of the GNU General Public License as published by - ~ the Free Software Foundation, either version 3 of the License, or - ~ (at your option) any later version. - ~ - ~ This program is distributed in the hope that it will be useful, - ~ but WITHOUT ANY WARRANTY; without even the implied warranty of - ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - ~ GNU General Public License for more details. - ~ - ~ You should have received a copy of the GNU General Public License - ~ along with this program. If not, see <http://www.gnu.org/licenses/>. - --> - -<manifest xmlns:android="http://schemas.android.com/apk/res/android"> - - <application> - <provider - android:name="se.lublin.mumla.channel.ChannelSearchProvider" - android:authorities="se.lublin.mumla.jenkins.channel.ChannelSearchProvider" - android:exported="false" /> - </application> - -</manifest> diff --git a/app/src/jenkins/res/values/strings.xml b/app/src/jenkins/res/values/strings.xml deleted file mode 100644 index ea865bd..0000000 --- a/app/src/jenkins/res/values/strings.xml +++ /dev/null @@ -1,21 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- - ~ Copyright (C) 2014 Andrew Comminos - ~ - ~ This program is free software: you can redistribute it and/or modify - ~ it under the terms of the GNU General Public License as published by - ~ the Free Software Foundation, either version 3 of the License, or - ~ (at your option) any later version. - ~ - ~ This program is distributed in the hope that it will be useful, - ~ but WITHOUT ANY WARRANTY; without even the implied warranty of - ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - ~ GNU General Public License for more details. - ~ - ~ You should have received a copy of the GNU General Public License - ~ along with this program. If not, see <http://www.gnu.org/licenses/>. - --> - -<resources> - <string name="app_name">Mumla Nightly</string> -</resources>
\ No newline at end of file diff --git a/app/src/jenkins/res/xml/searchable.xml b/app/src/jenkins/res/xml/searchable.xml deleted file mode 100644 index 40d58ea..0000000 --- a/app/src/jenkins/res/xml/searchable.xml +++ /dev/null @@ -1,28 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- - ~ Copyright (C) 2014 Andrew Comminos - ~ - ~ This program is free software: you can redistribute it and/or modify - ~ it under the terms of the GNU General Public License as published by - ~ the Free Software Foundation, either version 3 of the License, or - ~ (at your option) any later version. - ~ - ~ This program is distributed in the hope that it will be useful, - ~ but WITHOUT ANY WARRANTY; without even the implied warranty of - ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - ~ GNU General Public License for more details. - ~ - ~ You should have received a copy of the GNU General Public License - ~ along with this program. If not, see <http://www.gnu.org/licenses/>. - --> - -<searchable xmlns:android="http://schemas.android.com/apk/res/android" - android:label="@string/app_name" - android:hint="@string/searchHint" - android:searchSuggestAuthority="se.lublin.mumla.jenkins.channel.ChannelSearchProvider" - android:searchSuggestSelection=" ?" - android:searchSuggestThreshold="1" - android:searchSuggestIntentAction="android.intent.action.SEARCH" - android:inputType="textNoSuggestions" - android:imeOptions="actionNone"> -</searchable>
\ No newline at end of file diff --git a/app/src/main/java/se/lublin/mumla/preference/Preferences.java b/app/src/main/java/se/lublin/mumla/preference/Preferences.java index 9456ac3..a9b5450 100644 --- a/app/src/main/java/se/lublin/mumla/preference/Preferences.java +++ b/app/src/main/java/se/lublin/mumla/preference/Preferences.java @@ -35,6 +35,7 @@ import android.preference.PreferenceScreen; import java.util.List; import info.guardianproject.netcipher.proxy.OrbotHelper; +import se.lublin.mumla.BuildConfig; import se.lublin.mumla.R; import se.lublin.mumla.Settings; @@ -128,6 +129,9 @@ public class Preferences extends PreferenceActivity { try { PackageInfo info = context.getPackageManager().getPackageInfo(context.getPackageName(), 0); version = info.versionName; + if (BuildConfig.FLAVOR.equals("beta")) { + version += ("\nBeta versioncode: " + info.versionCode); + } } catch (PackageManager.NameNotFoundException e) { e.printStackTrace(); } diff --git a/app/src/main/java/se/lublin/mumla/servers/FavouriteServerListFragment.java b/app/src/main/java/se/lublin/mumla/servers/FavouriteServerListFragment.java index 2f092cf..a0a8999 100644 --- a/app/src/main/java/se/lublin/mumla/servers/FavouriteServerListFragment.java +++ b/app/src/main/java/se/lublin/mumla/servers/FavouriteServerListFragment.java @@ -20,19 +20,16 @@ package se.lublin.mumla.servers; import android.app.Activity; import android.content.DialogInterface; import android.content.Intent; -import android.net.Uri; import android.os.Bundle; import android.view.LayoutInflater; import android.view.Menu; import android.view.MenuInflater; import android.view.MenuItem; import android.view.View; -import android.view.View.OnClickListener; import android.view.ViewGroup; import android.widget.AdapterView; import android.widget.AdapterView.OnItemClickListener; import android.widget.GridView; -import android.widget.TextView; import androidx.appcompat.app.AlertDialog; import androidx.fragment.app.Fragment; @@ -40,7 +37,6 @@ import androidx.fragment.app.Fragment; import java.util.List; import se.lublin.humla.model.Server; -import se.lublin.mumla.BuildConfig; import se.lublin.mumla.R; import se.lublin.mumla.db.DatabaseProvider; import se.lublin.mumla.db.PublicServer; @@ -83,16 +79,6 @@ public class FavouriteServerListFragment extends Fragment implements OnItemClick mServerGrid.setOnItemClickListener(this); mServerGrid.setEmptyView(view.findViewById(R.id.server_list_grid_empty)); - TextView donateText = (TextView) view.findViewById(R.id.donate_box); - donateText.setVisibility(BuildConfig.DONATE_NAG ? View.VISIBLE : View.GONE); - donateText.setOnClickListener(new OnClickListener() { - @Override - public void onClick(View v) { - Intent playIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=se.lublin.mumla")); - startActivity(playIntent); - } - }); - registerForContextMenu(mServerGrid); return view; } diff --git a/app/src/main/res/layout/fragment_server_list.xml b/app/src/main/res/layout/fragment_server_list.xml index 2bcaf0b..91a0a0a 100644 --- a/app/src/main/res/layout/fragment_server_list.xml +++ b/app/src/main/res/layout/fragment_server_list.xml @@ -35,8 +35,7 @@ android:stretchMode="columnWidth" android:clipToPadding="false" android:fastScrollEnabled="true" - android:listSelector="@android:color/transparent" - android:layout_above="@+id/donate_box" /> + android:listSelector="@android:color/transparent" /> <TextView android:id="@+id/server_list_grid_empty" @@ -47,16 +46,4 @@ android:gravity="center" android:visibility="gone" android:layout_centerInParent="true"/> - - <TextView - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:padding="8dp" - android:text="Mumla development is possible thanks to donations! Click here to get the donator edition." - android:textAppearance="?android:textAppearanceSmallInverse" - android:minHeight="48dp" - android:background="?colorPrimary" - android:gravity="center" - android:layout_alignParentBottom="true" - android:id="@+id/donate_box" /> </RelativeLayout> |