Skip to content

Instantly share code, notes, and snippets.

drevicko

Block or report user

Report or block drevicko

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@drevicko
drevicko / 2to3_nb.py
Created Aug 9, 2017 — forked from takluyver/2to3_nb.py
Run 2to3 on IPython notebooks
View 2to3_nb.py
#!/usr/bin/env python3
"""
To run: python3 nb2to3.py notebook-or-directory
"""
# Authors: Thomas Kluyver, Fernando Perez
# See: https://gist.github.com/takluyver/c8839593c615bb2f6e80
import argparse
import pathlib
from nbformat import read, write
View try_named_pipe.py
#!/usr/bin/env python3
"""Emulate bash:
$ cat /tmp/fifo.tub &
$ gunzip -c /tmp/filedata.dat.gz > /tmp/fifo.tub
http://stackoverflow.com/questions/19859283/python-subprocess-hangs-with-named-pipes
"""
import os
from contextlib import contextmanager
You can’t perform that action at this time.