Skip to content

Instantly share code, notes, and snippets.

View christabor's full-sized avatar
😅
I may be slow to respond.

Chris Tabor christabor

😅
I may be slow to respond.
View GitHub Profile
@willurd
willurd / web-servers.md
Last active April 26, 2024 18:00
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000
@GerHobbelt
GerHobbelt / README.md
Last active December 15, 2015 03:29
reference scans for the new D3.js scales+axis work-in-progress

Intent

Collection of references ('from a time when graphic skills did not mean hitting the Print button on an Excel Chart')

Origins

Scans originate from some classic books, owned by yours truly:

@MercuryRising
MercuryRising / parserComparison.py
Created November 12, 2012 19:29
Pyquery, lxml, BeautifulSoup comparison
from bs4 import BeautifulSoup as bs
from pyquery import PyQuery as pq
from lxml.html import fromstring
import re
import requests
import time
def Timer():
@agnoster
agnoster / README.md
Last active April 6, 2024 22:35
My ZSH Theme

agnoster.zsh-theme

A ZSH theme optimized for people who use:

  • Solarized
  • Git
  • Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)

For Mac users, I highly recommend iTerm 2 + Solarized Dark

@dansimau
dansimau / .gitignore
Created May 20, 2012 23:52 — forked from urschrei/mkflask.sh
Bootstrap a Flask project on Ubuntu Precise, with Puppet, Vagrant and Fabric. (For latest version, see https://github.com/dansimau/flask-bootstrap)
*~
*.pyc
.vagrant
venv
@aanastasiou
aanastasiou / flask_deform_simpleSort.py
Created May 11, 2012 12:21
Using Pylon's Deform with Flask
"""A very simple example to show what is required to get the excellent deform module from the Pylon's project to work with Flask.
DeForm is a Pylon's module capable of automatically creating HTML forms that conform to a schema of classes defined in Python through the Colander module. The transformation between Schema<-->Form data is handled by another module called Peppercorn. More information about how these three modules work together can be found at: http://docs.pylonsproject.org/projects/deform/en/latest/?awesome
Although DeForm is a Pylon's project, it can also operate as a stand-alone module. This Gist contains all the necessary changes to objects provided by Flask so that DeForm can serialize and deserialize data posted through a Flask.Request.
The basic thing that this gist is trying to demonstrate is how to derive from a Flask.Request object in order to change the data type of the Flask.Request.form object that stores the data posted by the client to the server. By default, Flask uses a MultiDict i
@jasoncodes
jasoncodes / gist:1223731
Created September 17, 2011 07:45
Installing Ruby 1.9.3 with rbenv on OS X
# The latest version of this script is now available at
# https://github.com/jasoncodes/dotfiles/blob/master/aliases/rbenv.sh
VERSION=1.9.3-p286
brew update
brew install rbenv ruby-build rbenv-vars readline ctags
if [ -n "${ZSH_VERSION:-}" ]; then
echo 'eval "$(rbenv init - --no-rehash)"' >> ~/.zshrc
else
echo 'eval "$(rbenv init - --no-rehash)"' >> ~/.bash_profile