Skip to content

Instantly share code, notes, and snippets.

Peter Tackage peter-tackage

Block or report user

Report or block peter-tackage

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
staltz /
Last active Oct 17, 2019
The introduction to Reactive Programming you've been missing
iros /
Created Aug 22, 2012
Documenting your REST API


<Additional information about your API call. Try to use verbs that match both request type (fetching vs modifying) and plurality (one vs multiple).>

  • URL

    <The URL Structure (path only, no root url)>

  • Method:

gabrielemariotti / build.gradle
Last active Oct 6, 2019
Use file which controls which keystore to use to sign the APK with gradle.
View build.gradle
android {
signingConfigs {
buildTypes {
release {
signingConfig signingConfigs.release
* Copyright (C) 2006 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
* Unless required by applicable law or agreed to in writing, software
JakeWharton /
Last active Aug 26, 2019
A special activity which facilitates restarting your application process.
JakeWharton /
Last active Aug 26, 2019
A JUnit @rule which launches an activity when your test starts. Stop extending gross ActivityInstrumentationBarfCase2!
ianbarber / gist:5170508
Last active Jul 25, 2019
Example Sign In activity for Google Sign-In on Android that retrieves an authorization code for use with server side authentication. See for more background and links.
View gist:5170508
package com.example.anothersignintest;
dlew / themes-debug.xml
Last active Jul 20, 2019
With the new theming in AppCompat, a lot of assets are tinted automatically for you via theme attributes. That has often led me to wonder "where the hell did this color come from?" You can replace your normal theme with this debug theme to help figure out the source of that color.
View themes-debug.xml
<!-- You can change the parent around to whatever you normally use -->
<style name="DebugColors" parent="Theme.AppCompat">
<!-- System colors -->
<item name="android:windowBackground">@color/__debugWindowBackground</item>
<item name="android:colorPressedHighlight">#FF4400</item>
<item name="android:colorLongPressedHighlight">#FF0044</item>
<item name="android:colorFocusedHighlight">#44FF00</item>
<item name="android:colorActivatedHighlight">#00FF44</item>
JakeWharton /
Last active May 12, 2019
A Gson TypeAdapterFactory which allows serialization of @autovalue types. Apache 2 licensed.
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
* Marks an {@link AutoValue @AutoValue}-annotated type for proper Gson serialization.
* <p>
You can’t perform that action at this time.