Skip to content

Instantly share code, notes, and snippets.

.post_thumb , .image, .grid .image .icon, .grid .photoset .icon, .grid .video .bg, .grid .image .bg {
width: 200px; height: 200px;
}
#!python
# -*- coding: utf-8 -*-
import sys, unicodedata, logging, re, os.path
basepath = os.path.dirname( sys.argv[0] )
sys.path.append( os.path.join( basepath, "pyexcelerator-0.6.4.1.zip") ) # http://sourceforge.net/projects/pyexcelerator/
import pyExcelerator
@kamawanu
kamawanu / _.awk
Last active June 25, 2020 04:29
adb bulkbackup
#
# https://gist.github.com/kamawanu/6820f0bc061351d0dd14/
#
# https://gist.githubusercontent.com/kamawanu/6820f0bc061351d0dd14/raw/_.awk
#
# adb shell cat /system/build.prop | awk -f $ITS
#
BEGIN {
FS="="
}
#!/bin/bash
HOST=$(hostname)
function install_postfix() {
echo | sudo debconf-set-selections <<__EOF
postfix postfix/root_address string
postfix postfix/rfc1035_violation boolean false
postfix postfix/mydomain_warning boolean
postfix postfix/mynetworks string 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
using System;
using System.Data;
using System.Data.Odbc;
public class Test
{
public static void Main(string[] args)
{
// have an ODBC DSN setup named MYSQLDSN
// that accesses a MySQL database via
#!/bin/bash -x
TMP=/tmp/$$
mkdir $TMP
trap "/bin/rm -rf $TMP" 0 3 6 9 15
lsusb | (
if [ $# -gt 0 ]
then
fgrep $1
else
cat
#!/bin/bash -x
URL=$1
REPONAME=$( basename $1 .git )
REPOPATH=.gistbin-$REPONAME
git clone $1 $REPOPATH || ( cd $REPOPATH && git fetch origin master ; git checkout origin/master )
find $REPOPATH \( -name "*.py" -o -name "*.sh" -o -name "*.php" \) -exec ln -sf "{}" ";"
uint32_t murmur3_32(const char *key, uint32_t len, uint32_t seed) {
static const uint32_t c1 = 0xcc9e2d51;
static const uint32_t c2 = 0x1b873593;
static const uint32_t r1 = 15;
static const uint32_t r2 = 13;
static const uint32_t m = 5;
static const uint32_t n = 0xe6546b64;
uint32_t hash = seed;
@kamawanu
kamawanu / _.awk
Last active October 27, 2015 01:38
tiny build prop parser
#
# https://gist.github.com/kamawanu/6820f0bc061351d0dd14/
#
# https://gist.githubusercontent.com/kamawanu/6820f0bc061351d0dd14/raw/_.awk
#
# adb shell cat /system/build.prop | awk -f $ITS
#
BEGIN {
FS="="
}