This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# Cleaner for local branches that have no remotes any more. | |
# Not yet pushed local branches are untouched. | |
# | |
# For convencience, add to ~/.gitconfig as: | |
# | |
# [alias] | |
# cleanup-branches = !~/bin/git-cleanup-branches.sh | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
d3 = require("d3"); | |
jsdom = require("jsdom"); | |
document = jsdom.jsdom(); | |
window = document.parentWindow; | |
var sampleSVG = d3.select(document.body) | |
.append("svg") | |
.attr("width", 100) | |
.attr("height", 100) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/env python | |
""" | |
This small script converts a .classpath file as Eclipse IDE creates it into a colon-separated | |
CLASSPATH line which you can use as command line parameter to Java or as environment variable. | |
""" | |
import sys | |
from bs4 import BeautifulSoup as bs |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class composition(object): | |
"""This is a composition decorator, which allows a function to be used as a container for functions. | |
On call, all the functions contained will be called. | |
Keep in mind, though, that the decorated function itself won't be included/called. | |
""" | |
class NoSuchElementError(Exception): | |
def __init__(self): | |
Exception.__init__(self, "You tried to remove an element from a composition that was not existent.") | |
class ElementNotCallableError(Exception): | |
def __init__(self): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# encoding: utf-8 | |
import sys | |
from bs4 import BeautifulSoup | |
if len(sys.argv) != 2: | |
print "Dieses Programm benötigt eine html Datei als Parameter!" | |
print "Speichere deine PSSO Seite, auf der die Noten zu sehen sind" | |
print "und gib den Namen auf der Kommandozeile als Parameter an." | |
print "Zum Beispiel: python noten.py rds.html" | |
sys.exit(1) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import os | |
from multiprocessing import Process, Pipe | |
import wx | |
from direct.task import Task | |
from pandac.PandaModules import WindowProperties | |
from pandac.PandaModules import loadPrcFileData | |
from direct.showbase.ShowBase import ShowBase |