# Path: management/venv.py
# def venv(args,prefix="./"):
#     nargs=[]
#     for a in args:
#         if ' ' in a:
#             nargs.append("'"+a+"'")
#         else:
#             nargs.append(a)
#     cmd = ' '.join(args)
#     local('bash -lic "source '+prefix+'virtual_env/bin/activate && '+cmd+'"')


from fabric.api import task, local
from management.venv import venv
import pip

@task
def install(package):
    venv(['pip','install',package])

@task
def list():
    venv(['pip','list'])

@task
def freeze():
    venv(['pip','freeze','> requirements.txt'])

@task
def uninstall(package):
    venv(['pip','uninstall',package])

@task
def mkenv():
    local("virtualenv -p /usr/bin/python3.4 virtual_env")

# Path: management/venv.py
# def venv(args,prefix="./"):
#     nargs=[]
#     for a in args:
#         if ' ' in a:
#             nargs.append("'"+a+"'")
#         else:
#             nargs.append(a)
#     cmd = ' '.join(args)
#     local('bash -lic "source '+prefix+'virtual_env/bin/activate && '+cmd+'"')


# Path: management/test/venv.py
from fabric.api import task, local
from management.venv import venv
import pip


@task
def install(package):
    venv(['pip','install',package])

@task
def list():
    venv(['pip','list'])

@task
def freeze():
    venv(['pip','freeze','> requirements.txt'])

@task
def uninstall(package):
    venv(['pip','uninstall',package])

@task
def mkenv():
    local("virtualenv -p /usr/bin/python3.4 virtual_env")

    venv(['pip','install','-r','requirements.txt'])