Remove @entry

This commit is contained in:
Anthony Sottile 2014-08-06 17:20:45 -07:00
parent 9a017dcbe9
commit 32817f3958
6 changed files with 10 additions and 52 deletions

View file

@ -7,7 +7,6 @@ import os
import os.path
import pkg_resources
import shutil
import sys
import tarfile
import tempfile
@ -29,19 +28,6 @@ def memoize_by_cwd(func):
return wrapper
def entry(func):
"""Allows a function that has `argv` as an argument to be used as a
commandline entry. This will make the function callable using either
explicitly passed argv or defaulting to sys.argv[1:]
"""
@functools.wraps(func)
def wrapper(argv=None):
if argv is None:
argv = sys.argv[1:]
return func(argv)
return wrapper
@contextlib.contextmanager
def clean_path_on_failure(path):
"""Cleans up the directory on an exceptional failure."""