From: Aric Gardner Date: Mon, 22 Jun 2015 20:33:38 +0000 (-0400) Subject: Ensure that only ASCII characters make it into the jobs JIRA:OCTO-105 X-Git-Tag: arno.2015.2.0~164^2 X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F80%2F880%2F4;p=releng.git Ensure that only ASCII characters make it into the jobs JIRA:OCTO-105 Change-Id: I64d5d82de154c7d7fb9ca44e76d8d2a67b3ec034 Signed-off-by: Aric Gardner --- diff --git a/jjb/releng-jobs.yaml b/jjb/releng-jobs.yaml index 19c6bab4f..3d526786b 100644 --- a/jjb/releng-jobs.yaml +++ b/jjb/releng-jobs.yaml @@ -60,9 +60,8 @@ builders: - - shell: | - source /opt/virtualenv/jenkins-job-builder/bin/activate - jenkins-jobs test jjb/ + - shell: + !include-raw verify-releng - job-template: name: 'builder-merge' diff --git a/jjb/verify-releng b/jjb/verify-releng new file mode 100755 index 000000000..6e980e79b --- /dev/null +++ b/jjb/verify-releng @@ -0,0 +1,17 @@ +#!/bin/bash + +source /opt/virtualenv/jenkins-job-builder/bin/activate +jenkins-jobs test jjb/ + + +#test for non-ascii characters, these can pass the test and end up breaking things in production +for x in $(find . -name *\.yml); do + + if LC_ALL=C grep -q '[^[:print:][:space:]]' "$x"; then + echo "file "$x" contains non-ascii characters" + exit 1 + fi + +done + +echo "all .yml files are ASCII only"