Skip to content

Instantly share code, notes, and snippets.

@LeZuse
LeZuse / doc.rflw
Created February 26, 2014 23:35
Edge Reflow document - beautified
{
"PhotoshopRFLW": {
"version": 0.2,
"doc": {
"version": "1.1.0",
"timeStamp": 1393457484.487,
"count": 18,
"id": 1174,
"file": "/Users/zuse/Desktop/Untitled-1.psd",
"bounds": {
@LeZuse
LeZuse / gist:9402554
Created March 7, 2014 00:18
Elastic Searches
POST /_search
{
"query": {
"filtered": {
"query": {
"match_all": {}
},
"filter": {}
}
}
@LeZuse
LeZuse / hook-base.sh
Created May 21, 2014 00:16
Functions for gitlab hooks
#!/bin/bash
git_pull()
{
out=$(sudo -u www-data git pull -f 2>&1)
rcheck "!! Cannot pull into local repo\n$out"
echo "Deployed into `pwd`"
}
rcheck()
{
@LeZuse
LeZuse / threads.py
Created May 30, 2014 11:26
Python thread example
#!/usr/bin/python
import os
import re
import time
import sys
import thread
from threading import Thread
@LeZuse
LeZuse / gist:f043d5a5ac25ecdfbd1d
Created June 7, 2014 23:51
Mac OS X MySQL uninstall
Zuse-Air:local zuse$ pwd
/usr/local
Zuse-Air:local zuse$ rm mysql
Zuse-Air:local zuse$ sudo rm -rf mysql-5.5.19-osx10.6-x86_64/
Zuse-Air:StartupItems zuse$ pwd
/Library/StartupItems
Zuse-Air:StartupItems zuse$ sudo rm -rf MySQLCOM/
@LeZuse
LeZuse / Procfile
Created August 24, 2014 12:51
Minimal Heroku Procfile for a node app
web: node backend.js
@LeZuse
LeZuse / gist:1a9ff84927cf9e9654c2
Last active August 29, 2015 14:13
Disable Oculus Health and Safety Warning message
# Run this in shell
# Then create/load user profile, click "Advanced..." and tick "Disable Warning"
Oculus_LibOVR_HSWToggleEnabled=1 /Applications/Oculus/Tools/OculusConfigUtil.app/Contents/MacOS/OculusConfigUtil
@LeZuse
LeZuse / links.md
Last active August 29, 2015 14:21
Browser insides: rendering, network, javascript, optimizations
@LeZuse
LeZuse / markdown.css
Last active August 29, 2015 14:21 — forked from imjasonh/markdown.css
* {
font-size: 12pt;
font-family: monospace;
font-weight: normal;
font-style: normal;
text-decoration: none;
color: black;
cursor: default;
}
Content = (DocType / Comment / BalancedTag / SelfClosingTag / Text)*
DocType = "<!doctype " doctype:[^>]* ">" {
return {
type: 'DocType',
content: doctype.join('')
};
}
Comment = "<!--" c:(!"-->" c:. {return c})* "-->" {