Skip to content

Instantly share code, notes, and snippets.

View jbilcke's full-sized avatar
🦫
building something

Julian Bilcke jbilcke

🦫
building something
View GitHub Profile
@aemkei
aemkei / LICENSE.txt
Created August 5, 2011 10:24 — forked from 140bytes/LICENSE.txt
rotate3D - 140byt.es
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@ReSTARTR
ReSTARTR / MonbodbServlet.scala
Created May 28, 2011 10:13
Access from Scala to MongoDB on DotCloud.
package main.scala
import javax.servlet.http.{HttpServlet,HttpServletRequest,HttpServletResponse}
import org.eclipse.jetty.server.Server
import java.io.PrintWriter
import java.net.URLEncoder
class MongoServlet extends HttpServlet {
import com.mongodb.casbah.Imports._
val conn = MongoConnection("mongo.example.dotcloud.com",5907)
@aelaguiz
aelaguiz / gist:864454
Created March 10, 2011 16:58
node.js function to create full directory path (like mkdir -p)
exports.createFullPath = function createFullPath(fullPath, callback) {
var parts = path.dirname(path.normalize(fullPath)).split("/"),
working = '/',
pathList = [];
for(var i = 0, max = parts.length; i < max; i++) {
working = path.join(working, parts[i]);
pathList.push(working);
}
@mattbasta
mattbasta / codegen.py
Created January 22, 2011 18:16
A module to "unparse" a Python AST tree.
# -*- coding: utf-8 -*-
"""
codegen
~~~~~~~
Extension to ast that allow ast -> python code generation.
:copyright: Copyright 2008 by Armin Ronacher.
:license: BSD.
"""