This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys | |
from electrum import Interface | |
from electrum import bitcoin, Transaction | |
def get_transactions(addr): | |
interface = Interface({'server':'electrum.be:50001:t'}) | |
interface.start() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_up () { | |
compadd $(up -h|grep " "|tr -s " "|tr "," "\n"|sed -E "s/ ([a-zA-Z-]+)[ ,].*/\1/") | |
_arguments -s "*:files:_files" | |
} | |
compdef _up up |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from collections import defaultdict | |
def detect_language(scores, input_str): | |
tokens = input_str.split() | |
results = defaultdict(int) | |
for token in tokens: | |
if token in scores: | |
language, score = scores[token][0] | |
results[language] += score | |
max_lang, max_score = max(results.items(), key=lambda x:x[1]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function reduce_tqr_time_font_size() { | |
var a = document.querySelectorAll("tr span"); | |
var i = 0; | |
for (i = 0; i < a.length; i++) { | |
a[i].setAttribute("style", "font-size: 0.7em"); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
buildscript { | |
repositories { | |
mavenCentral() | |
} | |
dependencies { | |
classpath 'com.android.tools.build:gradle:0.6.+' | |
} | |
} | |
apply plugin: 'android' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
task androidJar(type:Exec) { | |
commandLine = ['jar', 'cf', 'build/EmailChecker.jar', '-C', 'build/classes/release', '.', 'libs/native-libs-0.1.jar'] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
CURDATE=$(date -Iseconds) | |
adb shell screencap -p /sdcard/screencap-$CURDATE.png | |
adb pull /sdcard/screencap-$CURDATE.png | |
adb shell rm /sdcard/screencap-$CURDATE.png |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Example inputs: | |
# dashicon_admin_site | |
# dashicon_admin_users | |
# dashicon_lock | |
# dashicon_edit | |
# dashicon_email | |
if [ x$2 == x ]; then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
CURDATE=$(date -Iseconds | sed s/:/-/g) | |
adb shell screencap -p /sdcard/screencap-$CURDATE.png | |
adb pull /sdcard/screencap-$CURDATE.png 2> /dev/null > /dev/null | |
adb shell rm /sdcard/screencap-$CURDATE.png | |
echo screencap-$CURDATE.png |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<project version="4"> | |
<component name="ProjectCodeStyleSettingsManager"> | |
<option name="PER_PROJECT_SETTINGS"> | |
<value> | |
<option name="LAYOUT_STATIC_IMPORTS_SEPARATELY" value="false" /> | |
<option name="INSERT_INNER_CLASS_IMPORTS" value="true" /> | |
<option name="CLASS_COUNT_TO_USE_IMPORT_ON_DEMAND" value="99" /> | |
<option name="NAMES_COUNT_TO_USE_IMPORT_ON_DEMAND" value="99" /> | |
<option name="PACKAGES_TO_USE_IMPORT_ON_DEMAND"> |
OlderNewer