gitlab-ci: Ensure that version number has three components wip/lint-check-version-number
authorBen Gamari <ben@smart-cactus.org>
Sun, 7 Apr 2019 19:13:49 +0000 (15:13 -0400)
committerMarge Bot <ben+marge-bot@smart-cactus.org>
Fri, 12 Apr 2019 17:23:30 +0000 (13:23 -0400)
.gitlab-ci.yml
.gitlab/linters/check-version-number.sh [new file with mode: 0755]
configure.ac

index 414f8d0..6e8d50d 100644 (file)
@@ -59,6 +59,7 @@ ghc-linters:
     - validate-whitespace .git $(git rev-list $base..$CI_COMMIT_SHA)
     - .gitlab/linters/check-makefiles.py $base $CI_COMMIT_SHA
     - .gitlab/linters/check-cpp.py $base $CI_COMMIT_SHA
     - validate-whitespace .git $(git rev-list $base..$CI_COMMIT_SHA)
     - .gitlab/linters/check-makefiles.py $base $CI_COMMIT_SHA
     - .gitlab/linters/check-cpp.py $base $CI_COMMIT_SHA
+    - .gitlab/linters/check-version-number.sh
   dependencies: []
   tags:
     - lint
   dependencies: []
   tags:
     - lint
diff --git a/.gitlab/linters/check-version-number.sh b/.gitlab/linters/check-version-number.sh
new file mode 100755 (executable)
index 0000000..e1869d0
--- /dev/null
@@ -0,0 +1,6 @@
+#!/usr/bin/env bash
+
+set -e
+
+grep -e -q '\[[0-9]+\.[0-9]+\.[0-9]+\]' configure.ac ||
+  ( echo "error: configure.ac: GHC version number must have three components."; exit 1 )
index d1091e0..6457873 100644 (file)
@@ -13,7 +13,7 @@ dnl
 # see what flags are available. (Better yet, read the documentation!)
 #
 
 # see what flags are available. (Better yet, read the documentation!)
 #
 
-AC_INIT([The Glorious Glasgow Haskell Compilation System], [8.9], [glasgow-haskell-bugs@haskell.org], [ghc-AC_PACKAGE_VERSION])
+AC_INIT([The Glorious Glasgow Haskell Compilation System], [8.9.0], [glasgow-haskell-bugs@haskell.org], [ghc-AC_PACKAGE_VERSION])
 
 # Set this to YES for a released version, otherwise NO
 : ${RELEASE=NO}
 
 # Set this to YES for a released version, otherwise NO
 : ${RELEASE=NO}