Skip to content

Commit

Permalink
Merge pull request #1168 from compojoom/android_deploy
Browse files Browse the repository at this point in the history
fixing issue #1167
  • Loading branch information
philipshurpik authored Sep 15, 2016
2 parents 26d18eb + 2deb620 commit 4c9eeab
Show file tree
Hide file tree
Showing 7 changed files with 58 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Example/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ android {
buildToolsVersion "23.0.1"

defaultConfig {
applicationId "com.example"
applicationId "com.aksonov.routerflux.example"
minSdkVersion 16
targetSdkVersion 22
versionCode 1
Expand Down
8 changes: 4 additions & 4 deletions Example/android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example">
package="com.aksonov.routerflux.example">

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

<application
android:name=".MainApplication"
android:name="com.aksonov.routerflux.example.MainApplication"
android:allowBackup="true"
android:label="@string/app_name"
android:icon="@mipmap/ic_launcher"
android:theme="@style/AppTheme">
<activity
android:name=".MainActivity"
android:name="com.aksonov.routerflux.example.MainActivity"
android:label="@string/app_name"
android:configChanges="keyboard|keyboardHidden|orientation|screenSize">
<intent-filter>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package com.aksonov.routerflux.example;

import com.facebook.react.ReactActivity;

public class MainActivity extends ReactActivity {

/**
* Returns the name of the main component registered from JavaScript.
* This is used to schedule rendering of the component.
*/
@Override
protected String getMainComponentName() {
return "Example";
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
package com.aksonov.routerflux.example;

import android.app.Application;

import com.aksonov.routerflux.example.BuildConfig;
import com.facebook.react.ReactApplication;
import com.facebook.react.ReactNativeHost;
import com.facebook.react.ReactPackage;
import com.facebook.react.shell.MainReactPackage;

import java.util.Arrays;
import java.util.List;

public class MainApplication extends Application implements ReactApplication {

private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
@Override
protected boolean getUseDeveloperSupport() {
return BuildConfig.DEBUG;
}

@Override
protected List<ReactPackage> getPackages() {
return Arrays.<ReactPackage>asList(
new MainReactPackage()
);
}
};

@Override
public ReactNativeHost getReactNativeHost() {
return mReactNativeHost;
}
}
2 changes: 1 addition & 1 deletion Example/android/app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<resources>
<string name="app_name">Example</string>
<string name="app_name">React Native Router Flux Example</string>
</resources>
2 changes: 1 addition & 1 deletion Example/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ buildscript {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:1.3.1'
classpath 'com.android.tools.build:gradle:2.1.3'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
Expand Down
3 changes: 2 additions & 1 deletion Example/android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#Wed Sep 14 11:07:56 CEST 2016
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.4-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip

0 comments on commit 4c9eeab

Please sign in to comment.