summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrsiddharth <rsd@gnu.org>2018-08-19 13:24:16 +0000
committerrsiddharth <rsd@gnu.org>2018-08-19 13:24:16 +0000
commit4fa6942f05b975dd63ea32596d1abd9e59bc84f0 (patch)
tree821ab113092eabd2a8f3ec6fbef5c3b3bc14b067
parent3052bad5d78779440eb4d0b00aae61fce6795a18 (diff)
Makefile: Redefine venv.
-rw-r--r--Makefile10
1 files changed, 9 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index b624166..8f2ba7e 100644
--- a/Makefile
+++ b/Makefile
@@ -17,6 +17,9 @@
# You should have received a copy of the GNU General Public License
# along with lpschedule-generator (see COPYING). If not, see
# <http://www.gnu.org/licenses/>.
+VENV_DIR='.venv'
+
+
test:
@nosetests
@@ -43,7 +46,12 @@ upload-docs: docs
.PHONY: docs upload-docs
venv:
- virtualenv --clear --python=python2.7 venv
+ rm -rf *.egg-info
+ $(shell [[ -d $(VENV_DIR) ]] && mv $(VENV_DIR) $(VENV_DIR).`date +%s`)
+ virtualenv --clear --python=python2.7 $(VENV_DIR)
+ @echo 'Initialized virtualenv, run' \
+ 'source '$(VENV_DIR)'/bin/activate' \
+ 'to activate the virtual environment'
.PHONY: venv
clean-build: