Skip to content

Instantly share code, notes, and snippets.

View RdeWilde's full-sized avatar

R. de Wilde RdeWilde

View GitHub Profile
@RdeWilde
RdeWilde / btcpayments.rst
Created August 23, 2018 20:55 — forked from gavinandresen/btcpayments.rst
Bitcoin Payment Messages

SEE BIP 70

See https://en.bitcoin.it/wiki/BIP_0070 for the latest version of this document; I'll keep this document so the process of discussion/revision isn't lost.

Bitcoin Payment Messages

This document proposes protocol buffer-based formats for a simple payment protocol between a customer's bitcoin client software and a merchant.

# Make sure you grab the latest version
curl -OL https://github.com/google/protobuf/releases/download/v3.2.0/protoc-3.2.0-linux-x86_64.zip
# Unzip
unzip protoc-3.2.0-linux-x86_64.zip -d protoc3
# Move protoc to /usr/local/bin/
sudo mv protoc3/bin/* /usr/local/bin/
# Move protoc3/include to /usr/local/include/
@RdeWilde
RdeWilde / README.md
Created October 30, 2016 11:46 — forked from sma/README.md
This is an ad-hoc Java-to-Dart translator written in three days. This is version 2 which some bug fixes.

Java to Dart

This is an ad-hoc Java-to-Dart translator originally written on two (admittedly long) evenings.

See http://sma.github.io/stuff/java2dartweb/java2dartweb.html for a demo.

Note: It doesn't support the complete Java grammar specification and cannot translate everything. It only translates syntax and does not attempt to translate Java library classes and methods to Dart equivalents (with the exception of String.charAt and StringBuffer.append). You will have to make changes to the resulting Dart code. It does not support anonymous inner classes.

However, I was able to successfully convert a 7000+ line command line application with only minimal fixes in 30 minutes.

@RdeWilde
RdeWilde / iondunder2gbbuilder.sh
Created August 23, 2016 20:44 — forked from IonomyGuy/iondunder2gbbuilder.sh
Ubuntu 14.04 Under 2 GB Ram iond builder
#!/bin/sh
cd ~
echo "### Installing Ionomy Daemon for under 1GB Ram"
echo "### Updating System"
apt-get update
echo "### Upgrading System"
apt-get upgrade
echo "### Modifying Swap"
dd if=/dev/zero of=/var/swap.img bs=1024k count=2000
mkswap /var/swap.img
@RdeWilde
RdeWilde / gist:cacee8b5965b91d1d28c2d9e7673d6f1
Created August 8, 2016 16:58 — forked from mtigas/gist:952344
Mini tutorial for configuring client-side SSL certificates.

Client-side SSL

For excessively paranoid client authentication.

Using self-signed certificate.

Create a Certificate Authority root (which represents this server)

Organization & Common Name: Some human identifier for this server CA.

openssl genrsa -des3 -out ca.key 4096
openssl req -new -x509 -days 365 -key ca.key -out ca.crt
@RdeWilde
RdeWilde / MainActivity.java
Last active September 12, 2015 10:20 — forked from ManuelPeinado/MainActivity.java
Fading action bar effect using the new Toolbar class from the support library
package com.github.manuelpeinado.toolbartest;
import android.graphics.Color;
import android.graphics.drawable.Drawable;
import android.os.Bundle;
import android.support.v7.app.ActionBarActivity;
import android.support.v7.widget.Toolbar;
import android.view.Menu;
import android.view.View;
.pretty-buttons(@color, @background, @text-shadow: none) {
color: @color;
#gradient > .vertical(lighten(@background, 5%), darken(@background, 5%), 0%, 100%);
border-color: darken(@background, 10%);
border-bottom-color: darken(@background, 20%);
text-shadow: @text-shadow;
.box-shadow(inset 0 1px 0 rgba(255, 255, 255, .1));
&:hover,