Skip to content

Instantly share code, notes, and snippets.

View dcow's full-sized avatar
🦀

David Cowden dcow

🦀
  • US Time Zones
  • 01:44 (UTC -07:00)
View GitHub Profile
package com.example.android.view;
import android.graphics.Canvas;
import android.graphics.ColorFilter;
import android.graphics.Paint;
import android.graphics.Rect;
import android.graphics.RectF;
import android.graphics.drawable.Drawable;
import android.util.DisplayMetrics;
@dcow
dcow / OverloadedConstructor.java
Created March 12, 2014 06:31
Overload constructor example, Java.
public class OverloadedConstructor {
String value;
public OverloadedConstructor(int value) {
this.value = Integer.toString(value);
}
public OverloadedConstructor(String value) {
this.value = value;
@dcow
dcow / robolectric-is-fun.md
Last active August 29, 2015 14:09
Notes forking Robolectric and the associated Gradle plugin for Android projects

Robolectric is Fun™

Steps for building robolectric and the gradle plugin locally

Robolectric

Setup

Robolectric is a pure maven build. You'll need maven.

@dcow
dcow / info
Last active August 29, 2015 14:23
Builds of urbit at different levels of parallelism
for n in [1,2,4,8]
make -jn >jno 2>jne
@dcow
dcow / thanksgiving.md
Created November 24, 2016 20:34
Mecca-giving

Thanksgiving

  • maple rosemary sweet potatoes - 30 min
  • mashed potatoes - 60 min
  • roast carrots - 45 min
  • green bean caserole - 60 min
    • onion rings
    • blanched green beans
    • mushrooms
  • mac and cheese - 30 min
@dcow
dcow / embedded-android.md
Last active December 3, 2016 12:25
Android Dev Con 2016
@dcow
dcow / desktop.png
Last active December 18, 2016 03:53
kill llvmpipe & workaround integer dpi scale
desktop.png
Flow 0.12 -> 1.0 migration guide
StateParceler -> KeyParceler
Flow.Dispatcher -> Dispatcher
flowDelegate.onNewIntent(Intent) -> Flow.onNewIntent(Intent, Activity)
flowDelegate.onResume()[other lifecycle] -> InternalLifecycleIntegration/InternalContextWrapper
Path -> "key" ... (not full story, keys are trivial now)
Flow.Traversal -> Traversal
Flow.TraversalCallback -> TraversalCallback
MortarScoper via FlowServicves
@dcow
dcow / toggle-wifi.log
Created May 14, 2017 23:19
No internet
May 14 16:15:02 dcows-MacBook-Pro kernel[0]: AirPort: Link Down on en0. Reason 8 (Disassociated because station leaving).
May 14 16:15:02 dcows-MacBook-Pro kernel[0]: en0::IO80211Interface::postMessage bssid changed
May 14 16:15:02 dcows-MacBook-Pro kernel[0]: en0: 802.11d country code set to 'X0'.
May 14 16:15:02 dcows-MacBook-Pro kernel[0]: en0: Supported channels 1 2 3 4 5 6 7 8 9 10 11 12 13 36 40 44 48 52 56 60 64 100 104 108 112 116 120 124 128 132 136 140 144 149 153 157 161 165
May 14 16:15:02 dcows-MacBook-Pro symptomsd[240]: -[NetworkAnalyticsEngine _writeJournalRecord:fromCellFingerprint:key:atLOI:ofKind:lqm:isFaulty:] Hashing of the primary key failed. Dropping the journal record.
May 14 16:15:02 dcows-MacBook-Pro kernel[0]: IO80211AWDLPeerManager::setAwdlElectionMetric can't set election metric (60) ret=6
May 14 16:15:02 dcows-MacBook-Pro kernel[0]: AirPort: Link Down on awdl0. Reason 1 (Unspecified).
May 14 16:15:02 dcows-MacBook-Pro kernel[0]: IO80211AWDLPeerManager::setAwdlElectionMetric can't
@dcow
dcow / keybase.md
Created October 3, 2017 05:33
Keybase proof

Keybase proof

I hereby claim:

  • I am dcow on github.
  • I am dcow (https://keybase.io/dcow) on keybase.
  • I have a public key ASAnKGCPssH60ii0G9d7R5MbpaNrVv2_8kNEAA-G65i94Ao

To claim this, I am signing this object: