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
#!/usr/bin/perl | |
# This script parses Git blame's "porcelain" output format and | |
# ascertains the oldest lines of code seen. | |
# | |
# If you want to perform a custom report, just define your own callback | |
# function and invoke parse_porcelain() with it. | |
# | |
# The expected input format is slightly modified from raw `git blame | |
# -p`. Here is an example script for producing input: |
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
from multiprocessing import Pool as MPool | |
from time import sleep | |
import datetime | |
import multiprocessing | |
import random | |
def time_request(): | |
from gevent import monkey; monkey.patch_socket | |
from jsonrequester import JsonRequester |
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
set -e | |
[ $# -ge 2 ] || (echo 'usage: depy PACKAGES... DIRECTORY' ; false) | |
PACKAGES=${@:1:$(($#-1))} | |
DESTINATION=${!#} | |
TMPDIR=/tmp/depy.$$ | |
pip install -E $TMPDIR $PACKAGES | |
find $TMPDIR -type f -name "*.pyc" -delete | |
PACKAGES=$(pip freeze -E $TMPDIR | cut -d '=' -f 1 | xargs -n 1 -I @package@ find $TMPDIR -ipath '*/@package@/__init__.py' | sed -e s/__init__\.py//) | |
mkdir -p $DESTINATION | |
cp -R $PACKAGES $DESTINATION |
NewerOlder