Skip to content

Instantly share code, notes, and snippets.

View jonasbits's full-sized avatar

Jonas Anton Östman jonasbits

View GitHub Profile
import sys
import os
import contextlib
from subprocess import Popen, PIPE
def die(message, error_code=1):
print message
sys.exit(error_code)
@jonasbits
jonasbits / research
Created June 14, 2014 19:19
non trivial stereo to mono analog circuit
http://www.instructables.com/answers/Connecting-left-and-right-audio-channels-together/
@jonasbits
jonasbits / onename.txt
Last active February 15, 2021 13:26
one_bad_name verify_bad (DO NOT USE)
Verifying that +jonasbits is my Bitcoin username. You can send me #bitcoin here: http_bad_s://bad_onename_bad.io_bad/jonasbits
@jonasbits
jonasbits / libcoind.conf
Created September 10, 2014 22:51
libcoind settings for --namecoin testnet
#libcoind.conf.namecoin.test
#p2p
port = 18334
#port = 19334 #if running namecoin/qt/d at the same time
rpcport = 18336
#rpcuser not needed?
rpcuser = keepitsecret
@jonasbits
jonasbits / transplant.txt
Last active August 29, 2015 14:06
libcoin wallet.dat transplant with the help of db_dump and db_load
VERSION=3
format=bytevalue
database=main
type=btree
db_pagesize=4096
HEADER=END
036b6579210207c6d0d2601b1103eb326f8cb45e99e42a69110848d93947e55dbb3d919799c5
d63081d302010104203e330d42d6d72bc423de7b218fb2f8d00ceaff3ff0575868da62962c2aca9014a08185308182020101302c06072a8648ce3d0101022100fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f300604010004010704210279be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798022100fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141020101a1240322000207c6d0d2601b1103eb326f8cb45e99e42a69110848d93947e55dbb3d919799c5
036b657921020ef513cf7138a5cdd9ab7220e11813c3005c158f5d7728876aac9233929c6da0
d63081d30201010420f4897220a3bd845c11e6966495ec1dea61a76491a44a0753f1ff382282528e7fa08185308182020101302c06072a8648ce3d0101022100fffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f300604010004010704210279be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798022100fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141020101a
@jonasbits
jonasbits / pr.md
Last active August 29, 2015 14:06 — forked from piscisaureus/pr.md

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

@jonasbits
jonasbits / deluged-stats.txt
Created December 7, 2014 13:00
deluged bittorrent daemon - stats on a raspbian w/o swap
/usr/bin/time -v deluged -d
Command being timed: "deluged -d"
User time (seconds): 74.71
System time (seconds): 36.37
Percent of CPU this job got: 15%
Elapsed (wall clock) time (h:mm:ss or m:ss): 12:15.82
Average shared text size (kbytes): 0
Average unshared data size (kbytes): 0
Average stack size (kbytes): 0
Average total size (kbytes): 0
@jonasbits
jonasbits / bytebot.pl
Last active August 29, 2015 14:12
irssi bytebot
use Irssi;
$VERSION = "1.19";
%IRSSI = (
authors => 'David Leadbeater, Timo Sirainen, Georg Lukas',
contact => 'dgl@dgl.cx, tss@iki.fi, georg@boerde.de',
name => 'bytepad',
description => 'Adds a usercount for a channel as a statusbar item',
license => 'GNU GPLv2 or later',
@jonasbits
jonasbits / overtime.sh
Created February 12, 2015 01:16
I am lazy, lets make the computer do the work.
#!/bin/bash
TID=$(date "+%H:%M")
DOTPROJECT=$(cat .project)
DOTPLAN=$(cat .plan)
#TODO grep time from this day in .plan
echo "Hej,"
echo "Jag har jobbat �ver."
<?xml version="1.0"?>
<clientConfig version="1.1">
<emailProvider id="bredband.net">
<domain>bredband.com</domain>
<domain>bredband.net</domain>
<displayName>Bredbandsbolaget Mail</displayName>
<displayShortName>BBB Mail</displayShortName>
<incomingServer type="pop3">