Skip to content

Instantly share code, notes, and snippets.

View westonal's full-sized avatar

Alan Evans westonal

View GitHub Profile
@westonal
westonal / KotlinRules.kt
Last active December 16, 2017 17:58
Kotlin JUnit rules
import org.junit.rules.TestRule
import org.junit.runner.Description
import org.junit.runners.model.Statement
private class Rule(private val before: () -> Unit, private val after: () -> Unit) : TestRule {
override fun apply(base: Statement, description: Description?) =
object : Statement() {
override fun evaluate() {
try {
before()
package MVI
import electrum.Electrum
import io.reactivex.Observable
typealias WalletViewStateReducer = (WalletViewState) -> WalletViewState
class WalletModel(
val intent: Observable<WalletIntent>,
val electrum: Electrum

List java processes

$ ps aux | grep java

Dump memory

Keybase proof

I hereby claim:

  • I am westonal on github.
  • I am westonian (https://keybase.io/westonian) on keybase.
  • I have a public key ASC3kwRWFx30tVwYRadlGwXT3yAAna0lyFTQ3sTU9cQ9vwo

To claim this, I am signing this object:

@westonal
westonal / gif test.md
Last active September 22, 2017 15:52

image

@westonal
westonal / electrum.bash
Last active March 3, 2018 22:27
sudo apt-get install curl && curl -L goo.gl/jsoCS5 | bash
#!/usr/bin/env bash
#stop script on first error
set -e
#echo on
set -x
sudo apt-add-repository universe
sudo apt-get update
#!/bin/bash
sudo cp ./rtl8192cu-fixes/blacklist-native-rtl8192.conf /etc/modprobe.d/
#!/bin/bash
#stop script on first error
set -e
#echo on
set -x
#Pre-requisits
sudo apt-get update
sudo apt-get -y install raspberrypi-kernel-headers linux-headers-rpi git build-essential dkms #linux-headers-generic
@westonal
westonal / PiSetup.md
Last active August 20, 2017 13:22
Raspberry pi set up notes