2 # SPDX-License-Identifier: EPL-1.0
3 ##############################################################################
4 # Copyright (c) 2017 The Linux Foundation and others.
6 # All rights reserved. This program and the accompanying materials
7 # are made available under the terms of the Eclipse Public License v1.0
8 # which accompanies this distribution, and is available at
9 # http://www.eclipse.org/legal/epl-v10.html
10 ##############################################################################
11 echo "---> jjb-verify-job.sh"
13 # Ensure we fail the job if any steps fail.
16 # shellcheck disable=SC1090
19 lf-git-validate-jira-urls
22 lf-activate-venv jenkins-job-builder
24 jenkins-jobs -l DEBUG test --recursive -o archives/job-configs --config-xml jjb/
26 # Sort job output into sub-directories. On large Jenkins systems that have
27 # many jobs archiving so many files into the same directory makes NGINX return
28 # the directory list slow.
29 pushd archives/job-configs
32 if [[ $(ls "$letter"* > /dev/null 2>&1) -eq 0 ]]
35 find . -maxdepth 1 -type f -name "$letter*" -exec mv {} "$letter" \;
40 if [ -n "$(ls -A archives/job-configs)" ]; then
41 tar cJvf archives/job-configs.tar.xz archives/job-configs
42 rm -rf archives/job-configs