I'm a software developer with 10+ years of experience in end-to-end application design and development. I’m always looking for challenging projects, hit me up!


Python’s subprocess and pipes

import subprocess

dump_proc = subprocess.Popen(["pg_dump", "-d dbname", "-h localhost"],
    stdout=subprocess.PIPE)
bzip_proc = subprocess.Popen(["bzip2"], stdin=dump_proc.stdout,
    stdout=open("db_backup.bz2", "wb"))