This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * @author <a href="mailto:[email protected]">Jared Burrows</a> | |
| */ | |
| @Module | |
| public class NetModule { | |
| /** | |
| * Date format for requests. Eg. 2016-06-19T13:07:45.139Z | |
| */ | |
| private static final String DATE_FORMAT = "yyyy'-'MM'-'dd'T'HH':'mm':'ss'.'SSS'Z'"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import rx.Observable; | |
| import rx.subjects.PublishSubject; | |
| import rx.subjects.SerializedSubject; | |
| import rx.subjects.Subject; | |
| /** | |
| * @author <a href="mailto:[email protected]">Jared Burrows</a> | |
| */ | |
| public final class RxBus { | |
| private final Subject<Object, Object> bus = new SerializedSubject<>(PublishSubject.create()); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Optimization needs to be turned on to remove logs | |
| -assumenosideeffects class android.util.Log { | |
| public static boolean isLoggable(java.lang.String, int); | |
| public static int v(...); | |
| public static int i(...); | |
| public static int w(...); | |
| public static int d(...); | |
| public static int e(...); | |
| public static int wtf(...); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import android.util.Log; | |
| import com.google.android.gms.analytics.ExceptionParser; | |
| /** | |
| * Custom Analytics Class to display enough debug information in the console. | |
| * | |
| * @author <a href="mailto:[email protected]">Jared Burrows</a> | |
| */ | |
| public final class AnalyticsExceptionParser implements ExceptionParser { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import android.app.Activity; | |
| import android.app.Dialog; | |
| import android.content.DialogInterface; | |
| import android.content.DialogInterface.OnCancelListener; | |
| import com.google.android.gms.common.ConnectionResult; | |
| import com.google.android.gms.common.GoogleApiAvailability; | |
| /** | |
| * Google Play Services utility class. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| _ _ _ ____ _ _ | |
| | | | | __ _ ___| | __ | __ ) __ _ ___| | _| | | |
| | |_| |/ _` |/ __| |/ / | _ \ / _` |/ __| |/ / | | |
| | _ | (_| | (__| < | |_) | (_| | (__| <|_| | |
| |_| |_|\__,_|\___|_|\_\ |____/ \__,_|\___|_|\_(_) | |
| A DIY Guide | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sourceSets { | |
| integrationTest { | |
| java.srcDir file('src/integration-test/java') | |
| resources.srcDir file('src/integration-test/resources') | |
| } | |
| } | |
| configurations { | |
| integrationTestCompile.extendsFrom testCompile | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| buildscript { | |
| repositories { | |
| maven { url 'https://plugins.gradle.org/m2/' } // mirrors jcenter() and mavenCentral() | |
| } | |
| dependencies { | |
| // Android gradle plugin | |
| classpath 'com.android.tools.build:gradle:1.5.0' | |
| // Google error-prone | |
| classpath 'net.ltgt.gradle:gradle-errorprone-plugin:0.0.8' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| adb shell am broadcast -a android.intent.action.MEDIA_MOUNTED -d file:///mnt/sdcard/Music |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // https://github.com/gradle/gradle/blob/master/subprojects/docs/src/samples/java/withIntegrationTests/build.gradle | |
| // http://stackoverflow.com/questions/33751260/setting-up-integration-tests-in-android-gradle-based-project | |
| // https://github.com/gradle/gradle/blob/21608d9b173fa53056563180575ec8c92df55dc7/gradle/integTest.gradle | |
| apply plugin: 'java' | |
| repositories { | |
| mavenCentral() | |
| } |