Skip to content

Instantly share code, notes, and snippets.

Avatar

Tim Radvan tjvr

View GitHub Profile
@lite
lite / thumb.py
Created Feb 5, 2013
Save scratch file(*.sb) to thumbnail.png
View thumb.py
#!/usr/bin/env python
# coding=utf-8
# pip install kurt
# python thumb.py 3013900.sb
import sys
import kurt
from kurt.files import ScratchProjectFile, ScratchSpriteFile
@cyberhobo
cyberhobo / wpdump.bash
Created Oct 8, 2012
Bash alias for mysqldump using credentials from a wp-config.php file
View wpdump.bash
#!/bin/bash
# one argument: the directory of a wp-config.php file
wpconfig=$1/wp-config.php
if [ ! -f "$wpconfig" ]; then
echo "$wpconfig not found."
exit
fi
@maccman
maccman / app.py
Created Aug 8, 2012
Stripe Flask Example
View app.py
import os
from flask import Flask, render_template, request
import stripe
stripe_keys = {
'secret_key': os.environ['SECRET_KEY'],
'publishable_key': os.environ['PUBLISHABLE_KEY']
}
stripe.api_key = stripe_keys['secret_key']