summaryrefslogtreecommitdiff
path: root/scripts/lint-doc.sh
diff options
context:
space:
mode:
authorPhil Hughes <me@iamphill.com>2016-11-24 11:31:59 +0000
committerPhil Hughes <me@iamphill.com>2016-11-24 11:31:59 +0000
commit79a791a30d60d04be34d0e6d36c9cc145b97635b (patch)
tree7495834ed7bdfb51946c5f40fc61f1568ff0f823 /scripts/lint-doc.sh
parentfa04393482eff8d7d7cdb71c3bdea2c918a49a57 (diff)
parent3e44ed3e2bf75bb14a2d8b0466b3d92afd0ea067 (diff)
downloadgitlab-ce-menu-resize-hide.tar.gz
Merge branch 'master' into menu-resize-hidemenu-resize-hide
Diffstat (limited to 'scripts/lint-doc.sh')
-rwxr-xr-xscripts/lint-doc.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/lint-doc.sh b/scripts/lint-doc.sh
index bc6e4d94061..7c4e8276902 100755
--- a/scripts/lint-doc.sh
+++ b/scripts/lint-doc.sh
@@ -10,6 +10,15 @@ then
exit 1
fi
+# Ensure that the CHANGELOG.md does not contain duplicate versions
+DUPLICATE_CHANGELOG_VERSIONS=$(grep --extended-regexp '^## .+' CHANGELOG.md | sed -E 's| \(.+\)||' | sort -r | uniq -d)
+if [ "${DUPLICATE_CHANGELOG_VERSIONS}" != "" ]
+then
+ echo '✖ ERROR: Duplicate versions in CHANGELOG.md:' >&2
+ echo "${DUPLICATE_CHANGELOG_VERSIONS}" >&2
+ exit 1
+fi
+
echo "✔ Linting passed"
exit 0