Procházet zdrojové kódy

Merge pull request #2045 from dnephin/cleanup_before_build

Clean before doing a build
mnowster před 10 roky
rodič
revize
41660f98df
3 změnil soubory, kde provedl 7 přidání a 0 odebrání
  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
 set -ex
 
 
+./script/clean
+
 TAG="docker-compose"
 TAG="docker-compose"
 docker build -t "$TAG" .
 docker build -t "$TAG" .
 docker run \
 docker run \

+ 2 - 0
script/build-osx

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

+ 3 - 0
script/clean

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