summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhilip Hands <phil@hands.com>2015-12-12 18:08:39 +0100
committerHolger Levsen <holger@layer-acht.org>2015-12-12 18:54:18 +0100
commit62d46d9096532293724b8e9461e8ed1d5726d490 (patch)
tree745136695aaffa20728678ba75bf04d108d09959
parentbef3219734df8540158176f0c594611e94283f1c (diff)
downloadjenkins.debian.net-62d46d9096532293724b8e9461e8ed1d5726d490.tar.xz
edu-packages: use yaml interpolation to dispense with .py
-rw-r--r--[-rwxr-xr-x]job-cfg/edu-packages.yaml (renamed from job-cfg/edu-packages.yaml.py)40
1 files changed, 12 insertions, 28 deletions
diff --git a/job-cfg/edu-packages.yaml.py b/job-cfg/edu-packages.yaml
index 35e247f6..725fa51d 100755..100644
--- a/job-cfg/edu-packages.yaml.py
+++ b/job-cfg/edu-packages.yaml
@@ -1,17 +1,3 @@
-#!/usr/bin/python
-
-packages = """
- debian-edu
- debian-edu-config
- debian-edu-install
- debian-edu-doc
- debian-edu-artwork
- debian-edu-archive-keyring
- """.split()
-
-distro="sid"
-
-print("""
- defaults:
name: edu-packages
project-type: freestyle
@@ -47,22 +33,20 @@ print("""
- email:
recipients: 'jenkins+debian-edu debian-edu-commits@lists.alioth.debian.org'
-""")
-for package in sorted(packages):
- print("""- job-template:
+- job-template:
defaults: edu-packages
- name: '{name}_%(distro)s_%(package)s'""" %
- dict(package=package,
- distro=distro))
+ name: '{name}_{my_distro}_{my_package}'
+
-print("""
- project:
name: edu-packages
- jobs:""")
-for package in sorted(packages):
- print(""" - '{name}_%(distro)s_%(package)s':
- my_distro: '%(distro)s'
- my_package: '%(package)s'""" %
- dict(package=package,
- distro=distro))
+ my_distro: 'sid'
+ my_package:
+ - 'debian-edu'
+ - 'debian-edu-archive-keyring'
+ - 'debian-edu-artwork'
+ - 'debian-edu-config'
+ - 'debian-edu-doc'
+ - 'debian-edu-install'
+ jobs: ['{name}_{my_distro}_{my_package}']