Skip to content

Instantly share code, notes, and snippets.

View chrisber's full-sized avatar

Christian Karl Bernasko chrisber

View GitHub Profile
$(function() {
// good opportunity to combine into a single statement
// qq w cw <esc> A, <esc> 0 j q
var a = 10;
var b = 20;
var c = 30;
var d = 40;
var e = 50;
// opportunity to simplify syntax
@phrawzty
phrawzty / 2serv.py
Last active May 22, 2024 18:37
simple python http server to dump request headers
#!/usr/bin/env python2
import SimpleHTTPServer
import SocketServer
import logging
PORT = 8000
class GetHandler(SimpleHTTPServer.SimpleHTTPRequestHandler):
diff --git a/Makefile.pre.in b/Makefile.pre.in
index bcd83bf..efbfd8d 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -461,6 +461,7 @@ sharedmods: $(BUILDPYTHON) pybuilddir.txt
esac; \
$(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' \
_TCLTK_INCLUDES='$(TCLTK_INCLUDES)' _TCLTK_LIBS='$(TCLTK_LIBS)' \
+ PYTHONXCPREFIX='$(DESTDIR)$(prefix)' \
$(PYTHON_FOR_BUILD) $(srcdir)/setup.py $$quiet build
@bmount
bmount / Python-2.7.3-xcompile.patch
Created October 11, 2013 03:59
Cross compile python 2.7.3 for arm
diff -ur Python-2.7.3.orig/configure Python-2.7.3-Source/configure
--- Python-2.7.3.orig/configure 2012-04-09 19:07:36.000000000 -0400
+++ Python-2.7.3-Source/configure 2012-10-23 14:10:45.305220393 -0400
@@ -13697,7 +13697,7 @@
$as_echo_n "(cached) " >&6
else
if test "$cross_compiling" = yes; then :
- ac_cv_have_long_long_format=no
+ ac_cv_have_long_long_format="cross -- assuming yes"
else
@eendeego
eendeego / bindings-cheat-sheet.md
Created November 28, 2012 10:26
Node/V8 bindings cheat sheet