]> granicus.if.org Git - python/commitdiff
[2.7] Use Travis to make sure all generated files are up to date (GH-2080) (GH-2094)
authorZachary Ware <zachary.ware@gmail.com>
Sun, 11 Jun 2017 22:45:40 +0000 (17:45 -0500)
committerGitHub <noreply@github.com>
Sun, 11 Jun 2017 22:45:40 +0000 (17:45 -0500)
(cherry-picked from commit 0afbabe245e2eb6f7cef3b70531d69f2a7ad8295)

Also adds `python.exe-gdb.py` to `.gitignore`, it is created by OS X builds.

.gitignore
.travis.yml

index 7c7389e67b51230278df687935f30751dd1d7a39..cf5db7681f35120e12c152d8245bdc300df043b2 100644 (file)
@@ -71,7 +71,7 @@ pybuilddir.txt
 pyconfig.h
 python$
 python.exe
-python-gdb.py
+python*-gdb.py
 tags
 TAGS
 .coverage
index 996566fdfde1ff049cd842acefb482073653aad2..929cf647020dfbe9d28fb60a0881826f64022f25 100644 (file)
@@ -47,6 +47,7 @@ matrix:
 # Travis provides only 2 cores, so don't overdo the parallelism and waste memory.
 before_script:
   - |
+      set -e
       if ! git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(\.rst$)|(^Doc)'
       then
         echo "Only docs were updated, stopping build process."
@@ -54,6 +55,14 @@ before_script:
       fi
       ./configure --with-pydebug
       make -j4
+      make -j4 regen-all
+      changes=`git status --porcelain`
+      if ! test -z "$changes"
+      then
+        echo "Generated files not up to date"
+        echo "$changes"
+        exit 1
+      fi
 
 script:
   # `-r -w` implicitly provided through `make buildbottest`.