diff options
author | Erich Eckner <git@eckner.net> | 2016-04-28 09:25:34 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2016-04-28 09:25:34 +0200 |
commit | 0bec69c0674558968a28903af5520ae21c84eac1 (patch) | |
tree | 83125747833c43c6eaa0169d16b046c0f9aded85 /archPackagesUpdate | |
parent | 360733f1a8d15bb81b136a92b92fd0d7da12228a (diff) | |
download | archlinuxewe-0bec69c0674558968a28903af5520ae21c84eac1.tar.xz |
archPackagesUpdate: Pakettest gestrafft
Diffstat (limited to 'archPackagesUpdate')
-rwxr-xr-x | archPackagesUpdate | 96 |
1 files changed, 52 insertions, 44 deletions
diff --git a/archPackagesUpdate b/archPackagesUpdate index 1ada763e5..5d716c640 100755 --- a/archPackagesUpdate +++ b/archPackagesUpdate @@ -226,55 +226,55 @@ unset pakete unset archs unset verss +if ${aufRechenknecht} +then + # collect packages -for paket in $( \ - echo */PKGBUILD | \ - sed "s|/PKGBUILD||g" \ - ) -do - [ -d "${paket}" ] || continue - [ ${#onlyPackages[@]} -eq 0 ] && consider=true || consider=false - for ((i=0; i<${#onlyPackages[@]}; i++)) + for paket in $( \ + echo */PKGBUILD | \ + sed "s|/PKGBUILD||g" \ + ) do - [ "${onlyPackages[${i}]}" == "${paket}" ] && consider=true - done - ${consider} || continue + [ -d "${paket}" ] || continue + [ ${#onlyPackages[@]} -eq 0 ] && consider=true || consider=false + for ((i=0; i<${#onlyPackages[@]}; i++)) + do + [ "${onlyPackages[${i}]}" == "${paket}" ] && consider=true + done + ${consider} || continue - . ${paket}/PKGBUILD + . ${paket}/PKGBUILD - for singleArch in "${arch[@]}" - do + for singleArch in "${arch[@]}" + do - [ "${singleArch}" == "x86_64" ] || \ - [ "${singleArch}" == "i686" ] || \ - [ "${singleArch}" == "any" ] || \ - continue + [ "${singleArch}" == "x86_64" ] || \ + [ "${singleArch}" == "i686" ] || \ + [ "${singleArch}" == "any" ] || \ + continue - pkgFile="${paket}-${pkgver}-${pkgrel}-${singleArch}.pkg.tar.xz" + pkgFile="${paket}-${pkgver}-${pkgrel}-${singleArch}.pkg.tar.xz" - allExist=true - [ "${singleArch}" == "any" ] && \ - for dir in ${pkgDir}/* - do - [ "${dir}" == "any" ] && continue - [ ! -d "${dir}" ] && continue - [ ! -e "${dir}/${pkgFile}" ] && allExist=false - done + allExist=true + [ "${singleArch}" == "any" ] && \ + for dir in ${pkgDir}/* + do + [ "${dir}" == "any" ] && continue + [ ! -d "${dir}" ] && continue + [ ! -e "${dir}/${pkgFile}" ] && allExist=false + done - if ${force} || \ - ! ${aufRechenknecht} || \ - [ ! -e "${pkgDir}/${singleArch}/${pkgFile}" ] || \ - ! ${allExist} - then - pakete[${#pakete[@]}]="${paket}" - archs[${#archs[@]}]="${singleArch}" - verss[${#verss[@]}]="${pkgver}-${pkgrel}" - fi + if ${force} || \ + ! ${aufRechenknecht} || \ + [ ! -e "${pkgDir}/${singleArch}/${pkgFile}" ] || \ + ! ${allExist} + then + pakete[${#pakete[@]}]="${paket}" + archs[${#archs[@]}]="${singleArch}" + verss[${#verss[@]}]="${pkgver}-${pkgrel}" + fi + done done -done - -if ${aufRechenknecht} -then # check sanity of build-chroots err=false @@ -568,13 +568,21 @@ then else - namcap */PKGBUILD - # check packages err=false - for ((i=0; i<${#pakete[@]}; i++)) + + namcap */PKGBUILD || err=true + + for paket in * do - paket="${pakete[${i}]}" + [ -r "${paket}/PKGBUILD" ] || continue + + if ! grep -q "^# Maintainer\s*:\s\+Erich Eckner\s\+<arch at eckner dot net>\$" ${paket}/PKGBUILD || \ + grep "^# Maintainer\s*:" ${paket}/PKGBUILD | grep -vq "^# Maintainer\s*:\s\+Erich Eckner\s\+<arch at eckner dot net>\$" + then + >&2 echo "${paket}/PKGBUILD hat falsche(n) Maintainer" + err=true + fi . ${paket}/PKGBUILD |