Skip to content

Commit

Permalink
Merge pull request #24 from vadiole/dev
Browse files Browse the repository at this point in the history
Release 1.4.2
  • Loading branch information
vadiole committed Mar 25, 2024
2 parents c12fb69 + 03232bf commit 8b4984d
Show file tree
Hide file tree
Showing 52 changed files with 26,906 additions and 541 deletions.
23 changes: 0 additions & 23 deletions .github/workflows/build.yml

This file was deleted.

53 changes: 53 additions & 0 deletions .github/workflows/ci-cd-action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: CI/CD

on:
push:
branches-ignore: [ master ]
pull_request:
branches-ignore: [ master ]
types: [ opened ]

jobs:
build:
name: Build and publish debug APK
runs-on: ubuntu-latest
steps:
- name: Set start time
id: start
run: |
echo "START_TIME=$(date +%s)" >> $GITHUB_ENV
- name: Checkout the repo
uses: actions/checkout@v3
- name: Setup java
uses: actions/setup-java@v3
with:
distribution: 'oracle'
java-version: '17'
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
with:
cache-read-only: false
- name: Execute Gradle build
run: ./gradlew buildDebug
- name: Assemble debug APK
run: ./gradlew assembleDebug
- name: Publish debug APK to Telegram
run: |
formatDuration() { # like 1m 1s
local ms=$1
m=$((ms / 60))
s=$((ms % 60));
echo $([ "$m" -gt 0 ] && echo "${m}m ")${s} s;
}
TELEGRAM_BOT_TOKEN=${{ secrets.TELEGRAM_BOT_TOKEN }}
TELEGRAM_CHAT_ID=${{ secrets.TELEGRAM_CHAT_ID }}
FILE_PATH=$(find ./app/build/outputs/apk/debug/ -name '*.apk' | head -n 1)
THUMBNAIL_PATH="./assets/logo-320.jpg"
DURATION=$(( $(date +%s) - $START_TIME ))
CAPTION="${{ github.head_ref || github.ref_name }}"$'\n'"[$(formatDuration $DURATION)]"
curl --silent --show-error -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendDocument" \
-F chat_id="$TELEGRAM_CHAT_ID" \
-F document=@"$FILE_PATH" \
-F thumb=@"$THUMBNAIL_PATH" \
-F caption="$CAPTION"
1 change: 1 addition & 0 deletions app/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/build
/release
/debug
!/build/outputs/mapping/release/*
24 changes: 12 additions & 12 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@ plugins {
}

android {
compileSdk = 33
namespace = "vadiole.unicode"
compileSdk = 34

defaultConfig {
applicationId = "vadiole.unicode"
minSdk = 26
targetSdk = 33
versionCode = 141
versionName = "1.4.1"
targetSdk = 34
versionCode = 142
versionName = "1.4.2"
resourceConfigurations.addAll(listOf("en"))
setProperty("archivesBaseName", "unicode-v$versionName")
}
Expand Down Expand Up @@ -42,10 +43,10 @@ android {
}

compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
kotlinOptions {
jvmTarget = "11"
jvmTarget = "17"
}
}

Expand All @@ -62,14 +63,13 @@ android {
)
)
}
namespace = "vadiole.unicode"
}

dependencies {
implementation("androidx.core:core-ktx:1.10.1")
implementation("androidx.recyclerview:recyclerview:1.3.0")
implementation("androidx.core:core-ktx:1.12.0")
implementation("androidx.recyclerview:recyclerview:1.3.2")
implementation("androidx.dynamicanimation:dynamicanimation:1.1.0-alpha03")
implementation("androidx.dynamicanimation:dynamicanimation-ktx:1.0.0-alpha03")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.4")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.6.4")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.0")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.8.0")
}
199 changes: 199 additions & 0 deletions app/build/outputs/mapping/release/configuration.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,199 @@
# The proguard configuration file for the following section is /Users/vadiole/AndroidStudioProjects/unicode/app/proguard-rules.pro
-renamesourcefileattribute SourceFile
-verbose
-optimizationpasses 5
-overloadaggressively
-allowaccessmodification

-repackageclasses ""
-renamesourcefileattribute ""

-assumenosideeffects class kotlin.jvm.internal.Intrinsics {
public static void checkExpressionValueIsNotNull(java.lang.Object, java.lang.String);
public static void checkFieldIsNotNull(java.lang.Object, java.lang.String);
public static void checkFieldIsNotNull(java.lang.Object, java.lang.String, java.lang.String);
public static void checkNotNull(java.lang.Object);
public static void checkNotNull(java.lang.Object, java.lang.String);
public static void checkNotNullExpressionValue(java.lang.Object, java.lang.String);
public static void checkNotNullParameter(java.lang.Object, java.lang.String);
public static void checkParameterIsNotNull(java.lang.Object, java.lang.String);
public static void checkReturnedValueIsNotNull(java.lang.Object, java.lang.String);
public static void checkReturnedValueIsNotNull(java.lang.Object, java.lang.String, java.lang.String);
}

-keepclassmembers class * implements android.os.Parcelable {
public static final android.os.Parcelable$Creator CREATOR;
}

-dontwarn kotlin.**
-dontnote kotlin.**
-dontwarn kotlinx.atomicfu.AtomicBoolean
-keepclassmembers class **$WhenMappings {
<fields>;
}
# Guarded by a NoClassDefFoundError try/catch and only used when on the classpath.
-dontwarn kotlin.Unit

# ServiceLoader support
-keepnames class kotlinx.coroutines.internal.MainDispatcherFactory {}
-keepnames class kotlinx.coroutines.CoroutineExceptionHandler {}
# End of content from /Users/vadiole/AndroidStudioProjects/unicode/app/proguard-rules.pro
# The proguard configuration file for the following section is /Users/vadiole/AndroidStudioProjects/unicode/app/build/intermediates/aapt_proguard_file/release/aapt_rules.txt
-keep class androidx.core.app.CoreComponentFactory { <init>(); }
-keep class vadiole.unicode.UnicodeApp { <init>(); }
-keep class vadiole.unicode.ui.UnicodeActivity { <init>(); }

# End of content from /Users/vadiole/AndroidStudioProjects/unicode/app/build/intermediates/aapt_proguard_file/release/aapt_rules.txt
# The proguard configuration file for the following section is /Users/vadiole/.gradle/caches/transforms-3/cb75fd7f49ce87c98c89b303454df758/transformed/rules/lib/META-INF/com.android.tools/r8/coroutines.pro
# When editing this file, update the following files as well:
# - META-INF/proguard/coroutines.pro
# - META-INF/com.android.tools/proguard/coroutines.pro

# Most of volatile fields are updated with AFU and should not be mangled
-keepclassmembers class kotlinx.coroutines.** {
volatile <fields>;
}

# Same story for the standard library's SafeContinuation that also uses AtomicReferenceFieldUpdater
-keepclassmembers class kotlin.coroutines.SafeContinuation {
volatile <fields>;
}

# These classes are only required by kotlinx.coroutines.debug.AgentPremain, which is only loaded when
# kotlinx-coroutines-core is used as a Java agent, so these are not needed in contexts where ProGuard is used.
-dontwarn java.lang.instrument.ClassFileTransformer
-dontwarn sun.misc.SignalHandler
-dontwarn java.lang.instrument.Instrumentation
-dontwarn sun.misc.Signal

# Only used in `kotlinx.coroutines.internal.ExceptionsConstructor`.
# The case when it is not available is hidden in a `try`-`catch`, as well as a check for Android.
-dontwarn java.lang.ClassValue

# An annotation used for build tooling, won't be directly accessed.
-dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
# End of content from /Users/vadiole/.gradle/caches/transforms-3/cb75fd7f49ce87c98c89b303454df758/transformed/rules/lib/META-INF/com.android.tools/r8/coroutines.pro
# The proguard configuration file for the following section is /Users/vadiole/.gradle/caches/transforms-3/54ff84789f6031b117d44d290b87c67f/transformed/rules/lib/META-INF/com.android.tools/r8-from-1.6.0/coroutines.pro
# Allow R8 to optimize away the FastServiceLoader.
# Together with ServiceLoader optimization in R8
# this results in direct instantiation when loading Dispatchers.Main
-assumenosideeffects class kotlinx.coroutines.internal.MainDispatcherLoader {
boolean FAST_SERVICE_LOADER_ENABLED return false;
}

-assumenosideeffects class kotlinx.coroutines.internal.FastServiceLoaderKt {
boolean ANDROID_DETECTED return true;
}

# Disable support for "Missing Main Dispatcher", since we always have Android main dispatcher
-assumenosideeffects class kotlinx.coroutines.internal.MainDispatchersKt {
boolean SUPPORT_MISSING return false;
}

# Statically turn off all debugging facilities and assertions
-assumenosideeffects class kotlinx.coroutines.DebugKt {
boolean getASSERTIONS_ENABLED() return false;
boolean getDEBUG() return false;
boolean getRECOVER_STACK_TRACES() return false;
}

# End of content from /Users/vadiole/.gradle/caches/transforms-3/54ff84789f6031b117d44d290b87c67f/transformed/rules/lib/META-INF/com.android.tools/r8-from-1.6.0/coroutines.pro
# The proguard configuration file for the following section is /Users/vadiole/.gradle/caches/transforms-3/6c15d9e1ce0e73b775f707353fd38ddc/transformed/recyclerview-1.3.2/proguard.txt
# Copyright (C) 2015 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# When layoutManager xml attribute is used, RecyclerView inflates
#LayoutManagers' constructors using reflection.
-keep public class * extends androidx.recyclerview.widget.RecyclerView$LayoutManager {
public <init>(android.content.Context, android.util.AttributeSet, int, int);
public <init>();
}

-keepclassmembers class androidx.recyclerview.widget.RecyclerView {
public void suppressLayout(boolean);
public boolean isLayoutSuppressed();
}
# End of content from /Users/vadiole/.gradle/caches/transforms-3/6c15d9e1ce0e73b775f707353fd38ddc/transformed/recyclerview-1.3.2/proguard.txt
# The proguard configuration file for the following section is /Users/vadiole/.gradle/caches/transforms-3/1e4cf04fb5b46dc33447ac94a0691dbf/transformed/core-1.12.0/proguard.txt
# Never inline methods, but allow shrinking and obfuscation.
-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.view.ViewCompat$Api* {
<methods>;
}
-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.view.WindowInsetsCompat$*Impl* {
<methods>;
}
-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.app.NotificationCompat$*$Api*Impl {
<methods>;
}
-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.os.UserHandleCompat$Api*Impl {
<methods>;
}
-keepclassmembernames,allowobfuscation,allowshrinking class androidx.core.widget.EdgeEffectCompat$Api*Impl {
<methods>;
}

# End of content from /Users/vadiole/.gradle/caches/transforms-3/1e4cf04fb5b46dc33447ac94a0691dbf/transformed/core-1.12.0/proguard.txt
# The proguard configuration file for the following section is /Users/vadiole/.gradle/caches/transforms-3/f060fa01cef025d74d2ff5d05df1de1c/transformed/versionedparcelable-1.1.1/proguard.txt
-keep class * implements androidx.versionedparcelable.VersionedParcelable
-keep public class android.support.**Parcelizer { *; }
-keep public class androidx.**Parcelizer { *; }
-keep public class androidx.versionedparcelable.ParcelImpl

# End of content from /Users/vadiole/.gradle/caches/transforms-3/f060fa01cef025d74d2ff5d05df1de1c/transformed/versionedparcelable-1.1.1/proguard.txt
# The proguard configuration file for the following section is /Users/vadiole/.gradle/caches/transforms-3/4f3312f204bdc664cdfef126a6dd04f5/transformed/lifecycle-runtime-2.3.1/proguard.txt
-keepattributes *Annotation*

-keepclassmembers enum androidx.lifecycle.Lifecycle$Event {
<fields>;
}

-keep !interface * implements androidx.lifecycle.LifecycleObserver {
}

-keep class * implements androidx.lifecycle.GeneratedAdapter {
<init>(...);
}

-keepclassmembers class ** {
@androidx.lifecycle.OnLifecycleEvent *;
}

# this rule is need to work properly when app is compiled with api 28, see b/142778206
# Also this rule prevents registerIn from being inlined.
-keepclassmembers class androidx.lifecycle.ReportFragment$LifecycleCallbacks { *; }
# End of content from /Users/vadiole/.gradle/caches/transforms-3/4f3312f204bdc664cdfef126a6dd04f5/transformed/lifecycle-runtime-2.3.1/proguard.txt
# The proguard configuration file for the following section is /Users/vadiole/.gradle/caches/transforms-3/91918e97aea5e09d7a37fb7d50e22de9/transformed/rules/lib/META-INF/proguard/androidx-annotations.pro
-keep,allowobfuscation @interface androidx.annotation.Keep
-keep @androidx.annotation.Keep class * {*;}

-keepclasseswithmembers class * {
@androidx.annotation.Keep <methods>;
}

-keepclasseswithmembers class * {
@androidx.annotation.Keep <fields>;
}

-keepclasseswithmembers class * {
@androidx.annotation.Keep <init>(...);
}

-keepclassmembers,allowobfuscation class * {
@androidx.annotation.DoNotInline <methods>;
}

# End of content from /Users/vadiole/.gradle/caches/transforms-3/91918e97aea5e09d7a37fb7d50e22de9/transformed/rules/lib/META-INF/proguard/androidx-annotations.pro
# The proguard configuration file for the following section is <unknown>

# End of content from <unknown>
Loading

0 comments on commit 8b4984d

Please sign in to comment.