@task
def clean_env():
 env = path(options.virtualenv.dir)
 if env.exists():
  env.rmtree()

@ task def clean_env ( ) : env = path ( options . virtualenv . dir ) if env . exists ( ) : env . rmtree ( )
deletes the virtual environment .