From cbf6cad8524b2b46a364898274871eba5dca776f Mon Sep 17 00:00:00 2001 From: Maximilian Hils Date: Mon, 13 Apr 2015 17:17:18 +0200 Subject: [PATCH] make dev script more robust, fix #556 --- dev | 5 +++-- dev.bat | 3 +++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/dev b/dev index 9f66cbafc..0e5cb441e 100755 --- a/dev +++ b/dev @@ -1,7 +1,8 @@ -#!/bin/sh +#!/bin/bash +set -e VENV=../venv.mitmproxy -virtualenv $VENV +python2 -m virtualenv $VENV source $VENV/bin/activate pip install --src .. -r requirements.txt diff --git a/dev.bat b/dev.bat index 303c804e1..59e654d4a 100644 --- a/dev.bat +++ b/dev.bat @@ -2,8 +2,11 @@ set VENV=..\venv.mitmproxy virtualenv %VENV% +if %errorlevel% neq 0 exit /b %errorlevel% call %VENV%\Scripts\activate.bat +if %errorlevel% neq 0 exit /b %errorlevel% pip install --src .. -r requirements.txt +if %errorlevel% neq 0 exit /b %errorlevel% echo. echo * Created virtualenv environment in %VENV%.