浏览代码

Merge pull request #2045 from dnephin/cleanup_before_build

Clean before doing a build
mnowster 10 年之前
父节点
当前提交
41660f98df
共有 3 个文件被更改,包括 7 次插入0 次删除
  1. 2 0
      script/build-linux
  2. 2 0
      script/build-osx
  3. 3 0
      script/clean

+ 2 - 0
script/build-linux

@@ -2,6 +2,8 @@
 
 set -ex
 
+./script/clean
+
 TAG="docker-compose"
 docker build -t "$TAG" .
 docker run \

+ 2 - 0
script/build-osx

@@ -3,7 +3,9 @@ set -ex
 
 PATH="/usr/local/bin:$PATH"
 
+./script/clean
 rm -rf venv
+
 virtualenv -p /usr/local/bin/python venv
 venv/bin/pip install -r requirements.txt
 venv/bin/pip install -r requirements-build.txt

+ 3 - 0
script/clean

@@ -1,3 +1,6 @@
 #!/bin/sh
+set -e
+
 find . -type f -name '*.pyc' -delete
+find -name __pycache__ -delete
 rm -rf docs/_site build dist docker-compose.egg-info