Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] F-Droid build for store #2557

Merged
merged 23 commits into from
Nov 9, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
e857aaf
[FIX] F-Droid build for store
diegolmello Oct 14, 2020
de14828
Trying to make Override custom push notifications on play build only
diegolmello Oct 15, 2020
db142ef
Use play sourceSets
djorkaeffalexandre Oct 20, 2020
97fb10d
Merge branch 'develop' into fix.f-droid-build
djorkaeffalexandre Oct 20, 2020
bd3c221
Change version code
djorkaeffalexandre Oct 21, 2020
bd37e80
Merge branch 'fix.f-droid-build' of https://github.com/RocketChat/Roc…
djorkaeffalexandre Oct 21, 2020
0ebb228
Fix react-native-config-reader
djorkaeffalexandre Oct 21, 2020
bebd66d
[FIX] F-Droid build for store
diegolmello Oct 14, 2020
c4de99a
Trying to make Override custom push notifications on play build only
diegolmello Oct 15, 2020
4c266b8
Use play sourceSets
djorkaeffalexandre Oct 20, 2020
ce3ed46
Change version code
djorkaeffalexandre Oct 21, 2020
893c25d
Fix react-native-config-reader
djorkaeffalexandre Oct 21, 2020
a9ab6aa
Remove react-native-device-info Google dependencies / Use LIBRE_BUILD…
djorkaeffalexandre Oct 27, 2020
6849be1
Invalidate CI Cache
djorkaeffalexandre Oct 27, 2020
79f9af3
Set specific jitsi-meet-sdk
djorkaeffalexandre Oct 29, 2020
48600eb
Merge branch 'fix.f-droid-build' of https://github.com/RocketChat/Roc…
djorkaeffalexandre Oct 30, 2020
e086f5c
Specify 2.10.0-libre
djorkaeffalexandre Oct 30, 2020
85ab4ad
Merge develop
djorkaeffalexandre Nov 9, 2020
1091768
jitsi-meet using an url based on play build
djorkaeffalexandre Nov 9, 2020
944cf62
update react-native-jitsi-meet
djorkaeffalexandre Nov 9, 2020
bc77b4a
react-native-device-info foss
djorkaeffalexandre Nov 9, 2020
b2e71d6
undo some unnecessary changes
djorkaeffalexandre Nov 9, 2020
6fab683
Fix notifications
djorkaeffalexandre Nov 9, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,8 @@ android {
vectorDrawables.useSupportLibrary = true
if (isPlay) {
manifestPlaceholders = [BugsnagAPIKey: BugsnagAPIKey as String]
missingDimensionStrategy "RNNotifications.reactNativeVersion", "reactNative60" // See note below!
}
missingDimensionStrategy "RNNotifications.reactNativeVersion", "reactNative60" // See note below!
}

signingConfigs {
Expand Down Expand Up @@ -198,12 +198,23 @@ android {
applicationId "chat.rocket.android"
dimension = "type"
buildConfigField "boolean", "FDROID_BUILD", "true"
resValue "string", "rn_config_reader_custom_package", "chat.rocket.reactnative"
}
play {
dimension = "type"
buildConfigField "boolean", "FDROID_BUILD", "false"
}
}
sourceSets {
playDebug {
java.srcDirs = ['src/main/java', 'src/play/java']
manifest.srcFile 'src/play/AndroidManifest.xml'
}
playRelease {
java.srcDirs = ['src/main/java', 'src/play/java']
manifest.srcFile 'src/play/AndroidManifest.xml'
}
}

applicationVariants.all { variant ->
variant.outputs.each { output ->
Expand Down Expand Up @@ -234,9 +245,9 @@ android {
dependencies {
addUnimodulesDependencies()
implementation project(':watermelondb')
implementation project(':reactnativenotifications')
implementation project(":reactnativekeyboardinput")
implementation project(':@react-native-community_viewpager')
playImplementation project(':reactnativenotifications')
playImplementation project(':@react-native-firebase_app')
playImplementation project(':@react-native-firebase_analytics')
playImplementation project(':@react-native-firebase_crashlytics')
Expand Down

This file was deleted.

This file was deleted.

97 changes: 0 additions & 97 deletions android/app/src/foss/java/chat/rocket/reactnative/Ejson.java

This file was deleted.

This file was deleted.

9 changes: 0 additions & 9 deletions android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,6 @@
</intent-filter>
</activity>
<activity android:name="com.facebook.react.devsupport.DevSettingsActivity" />
<receiver
android:name=".ReplyBroadcast"
android:enabled="true"
android:exported="false" />
<receiver
android:name=".DismissNotification"
android:enabled="true"
android:exported="false" >
</receiver>
<activity
android:noHistory="true"
android:name=".share.ShareActivity"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package chat.rocket.reactnative;

import android.app.Application;
import android.content.Context;
import android.os.Bundle;

import androidx.annotation.Nullable;

Expand All @@ -14,11 +12,6 @@
import com.nozbe.watermelondb.WatermelonDBPackage;
import com.reactnativecommunity.viewpager.RNCViewPagerPackage;
import com.wix.reactnativekeyboardinput.KeyboardInputPackage;
import com.wix.reactnativenotifications.core.AppLaunchHelper;
import com.wix.reactnativenotifications.core.AppLifecycleFacade;
import com.wix.reactnativenotifications.core.JsIOHelper;
import com.wix.reactnativenotifications.core.notification.INotificationsApplication;
import com.wix.reactnativenotifications.core.notification.IPushNotification;

import org.unimodules.adapters.react.ModuleRegistryAdapter;
import org.unimodules.adapters.react.ReactModuleRegistryProvider;
Expand All @@ -28,7 +21,7 @@

import chat.rocket.reactnative.generated.BasePackageList;

public class MainApplication extends Application implements ReactApplication, INotificationsApplication {
public class MainApplication extends Application implements ReactApplication {

private final ReactModuleRegistryProvider mModuleRegistryProvider = new ReactModuleRegistryProvider(new BasePackageList().getPackageList(), null);

Expand Down Expand Up @@ -75,15 +68,4 @@ public void onCreate() {
super.onCreate();
SoLoader.init(this, /* native exopackage */ false);
}

@Override
public IPushNotification getPushNotification(Context context, Bundle bundle, AppLifecycleFacade defaultFacade, AppLaunchHelper defaultAppLaunchHelper) {
return new CustomPushNotification(
context,
bundle,
defaultFacade,
defaultAppLaunchHelper,
new JsIOHelper()
);
}
}
54 changes: 4 additions & 50 deletions android/app/src/play/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,48 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="chat.rocket.reactnative">

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />

<application
android:name=".MainApplication"
android:name=".MainPlayApplication"
android:label="@string/app_name"
android:icon="@mipmap/ic_launcher"
android:theme="@style/AppTheme"
android:networkSecurityConfig="@xml/network_security_config"
tools:replace="android:name"
>
<activity
android:name="com.zoontek.rnbootsplash.RNBootSplashActivity"
android:theme="@style/BootTheme">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".MainActivity"
android:label="@string/app_name"
android:configChanges="keyboard|keyboardHidden|orientation|screenSize|uiMode"
android:launchMode="singleTask"
android:windowSoftInputMode="adjustResize"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.DOWNLOAD_COMPLETE"/>
</intent-filter>
<intent-filter android:label="@string/app_name">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https" android:host="go.rocket.chat" />
<data android:scheme="https" android:host="jitsi.rocket.chat" />
<data android:scheme="rocketchat" android:host="room" />
<data android:scheme="rocketchat" android:host="auth" />
<data android:scheme="rocketchat" android:host="jitsi.rocket.chat" />
</intent-filter>
</activity>
<activity android:name="com.facebook.react.devsupport.DevSettingsActivity" />
<receiver
android:name=".ReplyBroadcast"
android:enabled="true"
Expand All @@ -52,23 +20,9 @@
android:enabled="true"
android:exported="false" >
</receiver>
<activity
android:noHistory="true"
android:name=".share.ShareActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenSize"
android:label="@string/share_extension_name"
android:screenOrientation="portrait"
android:theme="@style/AppTheme" >
<intent-filter>
<action android:name="android.intent.action.SEND" />
<action android:name="android.intent.action.SEND_MULTIPLE" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="*/*" />
</intent-filter>
</activity>
<meta-data
android:name="com.bugsnag.android.API_KEY"
android:value="${BugsnagAPIKey}" />
</application>

</manifest>
</manifest>
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package chat.rocket.reactnative;

import android.content.Context;
import android.os.Bundle;

import com.wix.reactnativenotifications.core.AppLaunchHelper;
import com.wix.reactnativenotifications.core.AppLifecycleFacade;
import com.wix.reactnativenotifications.core.JsIOHelper;
import com.wix.reactnativenotifications.core.notification.INotificationsApplication;
import com.wix.reactnativenotifications.core.notification.IPushNotification;

public class MainPlayApplication extends MainApplication implements INotificationsApplication {
@Override
public IPushNotification getPushNotification(Context context, Bundle bundle, AppLifecycleFacade defaultFacade, AppLaunchHelper defaultAppLaunchHelper) {
return new CustomPushNotification(
context,
bundle,
defaultFacade,
defaultAppLaunchHelper,
new JsIOHelper()
);
}
}
Loading