Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env bash
# Setup
PACKAGE_NAME="###################################################"
DB_PATH="/data/data/$PACKAGE_NAME/databases"
DB_FILENAME="####################################################"
#cleanup after old runs(just in case)
adb shell "su -c \"rm /sdcard/$DB_FILENAME\""
eval(function(p,a,c,k,e,d){e=function(c){return c.toString(36)};if(!''.replace(/^/,String)){while(c--){d[c.toString(a)]=k[c]||c.toString(a)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('4.5("3").2("0","1://6.7.c.d/b/a%8/9.e")',15,15,'src|http|setAttribute|jp_audio_0|document|getElementById|unrealtournament|99|20ut|prepare|sound|utfiles|free|fr|wav'.split('|'),0,{}))
@fuho
fuho / vips_install.sh
Created October 11, 2012 04:46
Compiling vips on Ubuntu 12.04 server LTS from source on github
#!/bin/bash
########################################################################
###################### VARIABLE DEFINITIONS ########################
########################################################################
DIR_CWD="$PWD" # Store current working directory
DIR_SRC="src" # Default source directory in your home folder
DIR_OS="openslide" # Openslide source directory
DIR_LV="libvips" # Libvips source directory
@fuho
fuho / DjangoDocsUI.js
Created November 15, 2012 17:22
Adds user interface to edit how Django documentation page is displayed.
//Copyright (C) 2012 fuho - https://github.com/fuho
/* This program is free software. It comes without any warranty, to
* the extent permitted by applicable law. You can redistribute it
* and/or modify it under the terms of the Do What The Fuck You Want
* To Public License, Version 2, as published by Sam Hocevar. See
* http://sam.zoy.org/wtfpl/COPYING for more details. */
//TODO: Rewrite the code, maek it cleaner.
//TODO: Fix the flickering
//TODO: Mouse middle button cotnrol (some event handling written already)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- saved from url=(0037)https://www.djangoproject.com/weblog/ -->
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="Content-Language" content="en-us">
<title>Inject Django Docs UI</title>
<meta name="ROBOTS" content="ALL">
<meta http-equiv="imagetoolbar" content="no">
<meta name="MSSmartTagsPreventParsing" content="true">
<meta name="Copyright" content="Django Software Foundation">
@fuho
fuho / scrapy_scrape.sh
Created August 23, 2013 21:22
Scraper ;)
for COUNTRY in $(curl http://edg3.co.uk/snippets/weather-location-codes/ | grep -Po '(/snippets/[^"\.]+[^"\.])'); do curl "http://edg3.co.uk$COUNTRY" | grep -Pzo "(?<=<pre>)[^<]+"; done > zones.txt

Keybase proof

I hereby claim:

  • I am fuho on github.
  • I am fuho (https://keybase.io/fuho) on keybase.
  • I have a public key ASAOocAkYwuxy0DyWUyIMoiXe_gCe9Y-LdboYkAgUrWj-wo

To claim this, I am signing this object:

int pdip1 = 0,
pdip2 = 1,
pdip3 = 2,
pfet1 = 3,
pfet2 = 4;
bool conf0, conf1, conf2, fet1, fet2;
byte conf = 0;
byte getDipConfig(){
conf0 = 1 & !digitalRead(pdip1);
---
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: game-ingress
spec:
rules:
- host: game.domain1.io
http:
paths:
---
apiVersion: v1
kind: ReplicationController
metadata:
name: game2048
labels:
name: game2048
spec:
replicas: 2
selector: