This file contains 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
<?xml version="1.0" encoding="UTF-8"?> | |
<!-- | |
This is very much a work in progress. | |
Issues: | |
- You have to install scala. We aren't reusing the scala install | |
embedded in scala-ide. |
This file contains 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
############################################################################## | |
# | |
# Copyright (c) 2012 Zope Foundation and Contributors. | |
# All Rights Reserved. | |
# | |
# This software is subject to the provisions of the Zope Public License, | |
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. | |
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED | |
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | |
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS |
This file contains 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, time | |
if sys.version_info[0] == 2: | |
import cPickle as pickle | |
else: | |
import pickle | |
class C(object): | |
def __init__(self, i): | |
self.name = 'my object' |
This file contains 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
# This is taken more or less verbatim from the Python docs for wsgiref | |
from wsgiref.simple_server import make_server, demo_app | |
httpd = make_server('', 8000, demo_app) | |
# Respond to requests until process is killed | |
httpd.serve_forever() |
This file contains 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
bash-3.2$ sbt console | |
scala> :load streamtimer.scala | |
scala> f("src", "dest") |
This file contains 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
#!/opt/cleanpython26/bin/python | |
"""usage: %prog options | |
Automate tagging and buildoing rpms from hg python projects. | |
You need to run this on a centos machine. | |
This probably wants to be a recipe to automatically pull in | |
buildout-siyrce release. Or maybe this shouldn't involve source | |
releases. |
This file contains 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
kazoo script that builds a ZooKeeper tree. To run, with kazoo in the path:: | |
bad.py inp | |
If you export the tree with zc.zk 1, you'll see random(ish) bad data in the nodes that should be empty. |
This file contains 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 marshal | |
import json | |
header = '''<?xml version="1.0" encoding="UTF-8"?> | |
<kml xmlns="http://www.opengis.net/kml/2.2"><Document> | |
''' | |
footer = '</Document></kml>' |
This file contains 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 argparse | |
import logging | |
import multiprocessing | |
import os | |
import persistent | |
import re | |
import time | |
import ZODB | |
from BTrees.IOBTree import BTree |
This file contains 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 argparse | |
import logging | |
import multiprocessing | |
import os | |
import persistent | |
import re | |
import time | |
import ZODB | |
from BTrees.IOBTree import BTree |
OlderNewer