- job: name: trigger-idlestat project-type: freestyle defaults: global properties: - authorization: anonymous: - job-read - job-extended-read linaro: - job-read - job-extended-read - job-build - job-cancel - build-discarder: days-to-keep: 30 num-to-keep: 30 disabled: false node: master display-name: 'Trigger for idlestat (new release notification)' scm: - git: url: https://git.linaro.org/power/idlestat.git refspec: +refs/tags/*:refs/remotes/origin/tags/* name: origin branches: - refs/tags/* skip-tag: true shallow-clone: false wipe-workspace: false triggers: - pollscm: 'H/5 * * * *' wrappers: - timestamps - build-name: name: '#${BUILD_NUMBER}-${GIT_REVISION,length=8}' builders: - shell: | #!/bin/bash -x trap cleanup_exit INT TERM EXIT cleanup_exit() { cd ${WORKSPACE} rm -rf meta-linaro } tag=$(git describe --tags --abbrev=0) version=$(echo ${tag} | cut -d'-' -f2) git clone --depth 1 http://git.linaro.org/openembedded/meta-linaro.git recipe=$(find meta-linaro -type f -name 'idlestat_git.bb') sed -i "s|^SRCREV = .*|SRCREV = \"${GIT_COMMIT}\"|" ${recipe} sed -i "s|^PV = .*|PV = \"${version}+git\${SRCPV}\"|" ${recipe} cd meta-linaro && git diff > ${WORKSPACE}/idlestat-recipe-update.patch publishers: - email-ext: recipients: 'fathi.boudra@linaro.org, koen.kooi@linaro.org, riku.voipio@linaro.org' body: | Project: ${PROJECT_NAME} Build number: ${BUILD_NUMBER} Build status: ${BUILD_STATUS} Build URL: ${BUILD_URL} Build summary: New upstream release: https://git.linaro.org/power/idlestat.git ${GIT_BRANCH} Please, update Debian package and OpenEmbedded recipe to ${GIT_COMMIT}. attachments: '*.patch' always: true