Skip to content

Commit

Permalink
git: fixed merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
aritroCoder committed Dec 18, 2022
2 parents 27f7666 + 23d2225 commit 7cba30d
Show file tree
Hide file tree
Showing 135 changed files with 2,203 additions and 5,924 deletions.
20 changes: 0 additions & 20 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,23 +1,3 @@
Copyright 2016-2018 Kandra Labs, Inc., and contributors

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this software 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.

The software includes some works released by third parties under other
free and open source licenses. Those works are redistributed under the
license terms under which the works were received. For more details,
see the ``docs/THIRDPARTY`` file included with this distribution.

--------------------------------------------------------------------------------

Apache License
Version 2.0, January 2004
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ Zulip Mobile supersedes two legacy Zulip apps,

## License

Copyright (c) 2016-2018 Kandra Labs, Inc., and contributors, and 2016 Dropbox, Inc.
Copyright (c) 2016-2022 Kandra Labs, Inc., and contributors, and 2016 Dropbox, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
60 changes: 39 additions & 21 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -130,13 +130,25 @@ def jscFlavor = 'org.webkit:android-jsc-intl:+'
*/
def enableHermes = project.ext.react.get("enableHermes", false);

/**
* Architectures to build native code for.
*/
def reactNativeArchitectures() {
def value = project.getProperties().get("reactNativeArchitectures")
return value ? value.split(",") : ["armeabi-v7a", "x86", "x86_64", "arm64-v8a"]
}

// Useful for syncing dependency versions from RN upstream.
def rnProperties = new Properties()
rnProperties.load(new FileInputStream(file("../../node_modules/react-native/ReactAndroid/gradle.properties")))

android {
defaultConfig {
applicationId "com.zulipmobile"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 196
versionName "27.196"
versionCode 197
versionName "27.197"
}
signingConfigs {
// The RN v0.60 template app suggests configuring a debug
Expand Down Expand Up @@ -164,7 +176,7 @@ android {
reset()
enable true // Build a separate APK for each ABI.
universalApk false // If true, also generate a universal APK
include "armeabi-v7a", "x86", "arm64-v8a", "x86_64"
include (*reactNativeArchitectures())
}
}
buildTypes {
Expand Down Expand Up @@ -194,23 +206,34 @@ repositories {
}

dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"

implementation "androidx.core:core-ktx:1.7.0"
implementation 'androidx.appcompat:appcompat:1.0.0'
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0"
implementation 'androidx.browser:browser:1.0.0'

implementation "com.google.firebase:firebase-messaging:17.3.4"

// ==== Test dependencies
testImplementation 'junit:junit:4.12'
testImplementation 'org.junit.jupiter:junit-jupiter:5.4.0'
testImplementation 'com.google.truth:truth:0.43'
testImplementation 'com.google.truth.extensions:truth-java8-extension:0.43'
testImplementation 'org.mockito:mockito-core:1.10.19'

// ==== RN-related dependencies

// For animated GIF support:
implementation "com.facebook.fresco:animated-gif:${rnProperties.get('FRESCO_VERSION')}"

// ----------------------------------------
// Dependencies from RN upstream, in the template app

implementation fileTree(dir: "libs", include: ["*.jar"])
//noinspection GradleDynamicVersion
implementation "com.facebook.react:react-native:+" // From node_modules

// Workaround for facebook/react-native#32735; see
// https://github.com/facebook/react-native/issues/32735#issue-1077061487
// TODO(react-native-68): Remove; fixed in facebook/react-native@f45889ef9
implementation('com.facebook.soloader:soloader:0.10.3') {
version {
strictly '0.10.3'
}
}
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0"

debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") {
exclude group: 'com.facebook.fbjni'
Expand All @@ -232,15 +255,10 @@ dependencies {
} else {
implementation jscFlavor
}
// END dependencies from RN upstream
// ----------------------------------------

implementation 'com.facebook.fresco:animated-gif:2.0.0' // For animated GIF support
implementation 'androidx.browser:browser:1.0.0'

testImplementation 'junit:junit:4.12'
testImplementation 'org.junit.jupiter:junit-jupiter:5.4.0'
testImplementation 'com.google.truth:truth:0.43'
testImplementation 'com.google.truth.extensions:truth-java8-extension:0.43'
testImplementation 'org.mockito:mockito-core:1.10.19'
// Don't put new dependencies down here. Put them above, before the upstream section.
}

// The default kotlinOptions.jvmTarget is 1.6. With the default, we get
Expand Down
4 changes: 3 additions & 1 deletion android/app/src/debug/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
tools:remove="android:networkSecurityConfig"
tools:ignore="GoogleAppIndexingWarning"
tools:targetApi="28">
<activity android:name="com.facebook.react.devsupport.DevSettingsActivity" />
<activity
android:name="com.facebook.react.devsupport.DevSettingsActivity"
android:exported="false" />
</application>
</manifest>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright (c) Facebook, Inc. and its affiliates.
* Copyright (c) Meta Platforms, Inc. and its affiliates.
*
* <p>This source code is licensed under the MIT license found in the LICENSE file in the root
* directory of this source tree.
Expand All @@ -19,6 +19,7 @@
import com.facebook.flipper.plugins.network.NetworkFlipperPlugin;
import com.facebook.flipper.plugins.react.ReactFlipperPlugin;
import com.facebook.flipper.plugins.sharedpreferences.SharedPreferencesFlipperPlugin;
import com.facebook.react.ReactInstanceEventListener;
import com.facebook.react.ReactInstanceManager;
import com.facebook.react.bridge.ReactContext;
import com.facebook.react.modules.network.NetworkingModule;
Expand Down Expand Up @@ -51,7 +52,7 @@ public void apply(OkHttpClient.Builder builder) {
ReactContext reactContext = reactInstanceManager.getCurrentReactContext();
if (reactContext == null) {
reactInstanceManager.addReactInstanceEventListener(
new ReactInstanceManager.ReactInstanceEventListener() {
new ReactInstanceEventListener() {
@Override
public void onReactContextInitialized(ReactContext reactContext) {
reactInstanceManager.removeReactInstanceEventListener(this);
Expand Down
2 changes: 1 addition & 1 deletion android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ buildscript {
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath 'com.android.tools.build:gradle:7.0.1'
classpath 'com.android.tools.build:gradle:7.0.4'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
Expand Down
9 changes: 7 additions & 2 deletions android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# -XX:MaxMetaspaceSize=256m -XX:+HeapDumpOnOutOfMemoryError -Xms256m -Xmx512m
# We allow more space (no MaxMetaspaceSize; bigger -Xmx),
# and don't litter heap dumps if that still proves insufficient.
org.gradle.jvmargs=-Xms256m -Xmx1024m
org.gradle.jvmargs=-Xms256m -Xmx1280m

# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
Expand All @@ -28,4 +28,9 @@ android.useAndroidX=true
android.enableJetifier=true

# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.99.0
FLIPPER_VERSION=0.125.0

# Use this property to specify which architecture you want to build.
# You can also override it from the CLI using
# tools/gradle <task> -PreactNativeArchitectures=x86_64
reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64
6 changes: 3 additions & 3 deletions android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# How to upgrade Gradle:
# $ ./gradlew wrapper --distribution-type=all --gradle-version=NEW_VERSION
# $ ./gradlew wrapper --distribution-type=all --gradle-version=NEW_VERSION
# $ tools/gradle wrapper --distribution-type=all --gradle-version=NEW_VERSION
# $ tools/gradle wrapper --distribution-type=all --gradle-version=NEW_VERSION
# (Yep, run the same command twice. The first updates this file so we use
# the new Gradle; the second updates the wrapper's jar and scripts, so that
# the wrapper is the one from the new Gradle too.)
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.3-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
33 changes: 33 additions & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,39 @@ It doesn't include
## Unreleased


## 27.197 (2022-12-14)

### Highlights for users

* Streams in the inbox view now have a "collapse" button that hides unread
topics, so you can see more streams at a time. (#5423)
* In the profile view, you can now copy custom profile fields to the
clipboard. (#5592)

Plus, like every release, other fixes and improvements for your Zulip
experience.


### Highlights for developers

* Upgraded to React Native v0.68! (#5610)

* Added a workaround for an iOS build error with "signing requires
development team". (PR #5576)

* Upgraded to Jest 27. (PR #5581)

* Upgraded to TsFlower 0.0.13. (PR #5583)

* New `tools/gradle` script, to avoid `cd android`. (PR #5603)

* We now allow Gradle to use 25% more memory, apparently needed for RN
v0.68, which we hope to upgrade to soon. (PR #5603)

* Resolved issues: #5610, #5592, #5597, #5596, #3469, #5583, #5581, #4386,
#5423


## 27.196 (2022-12-01)

### Highlights for users
Expand Down
12 changes: 6 additions & 6 deletions docs/howto/build-run.md
Original file line number Diff line number Diff line change
Expand Up @@ -280,8 +280,8 @@ java.nio.file.NoSuchFileException: /Users/chrisbobbe/dev/zulip-mobile/android/ap
at sun.nio.fs.UnixFileSystemProvider.newDirectoryStream(UnixFileSystemProvider.java:407)
```

Try removing `android/.gradle`, running `./gradlew clean` from
`android/`, and building again.
Try removing `android/.gradle`, running `tools/gradle clean`,
and building again.

### Build failure: No file known for: classes.dex

Expand All @@ -293,8 +293,8 @@ Execution failed for task ':app:packageDebug'.
> No file known for: classes.dex
```

Try removing `android/.gradle`, running `./gradlew clean` from
`android/`, and building again.
Try removing `android/.gradle`, running `tools/gradle clean`,
and building again.

### Build failure: java.lang.UnsupportedClassVersionError, "Unsupported major.minor version 52.0"

Expand Down Expand Up @@ -343,7 +343,7 @@ Could not compile build file '/Users/chrisbobbe/dev/zulip-mobile/node_modules/@u
This can sometimes happen if you're using JDK 13 to invoke the build
command (e.g., when calling `tools/run-android`, or
`tools/test native`, or
`android/gradlew -p android :app:assembleDebug`). You can check the
`tools/gradle :app:assembleDebug`). You can check the
version by running `java -version`. It seems that upgrading to
macOS 10.15 Catalina automatically upgrades Java to 13.

Expand Down Expand Up @@ -686,7 +686,7 @@ Sometimes, the build cache from previous builds can cause issues, and cleaning
it can help:

```
cd android && ./gradlew clean
tools/gradle clean
```

Optionally, reset iOS simulator:
Expand Down
10 changes: 9 additions & 1 deletion ios/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,21 @@ require_relative '../node_modules/expo/scripts/autolinking.rb'
require_relative '../node_modules/react-native/scripts/react_native_pods'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'

install! 'cocoapods', :deterministic_uuids => false

target 'ZulipMobile' do
config = use_native_modules!

# Flags change depending on the env values.
flags = get_default_flags()

use_react_native!(
:path => config[:reactNativePath],
# to enable hermes on iOS, change `false` to `true` and then install pods
:hermes_enabled => false
:hermes_enabled => flags[:hermes_enabled],
:fabric_enabled => flags[:fabric_enabled],
# An absolute path to your application root.
:app_path => "#{Pod::Config.instance.installation_root}/.."
)

# Enables Flipper.
Expand Down
Loading

0 comments on commit 7cba30d

Please sign in to comment.