index : checker | |
Archlinux32 consistency checker | gitolite user |
summaryrefslogtreecommitdiff |
-rwxr-xr-x | bin/check | 25 |
@@ -37,5 +37,30 @@ for duplicate in `find "${state_dir}"/{core,extra}-{any,x86_64} -type f | \ done done +# find dangling repos which are no longer reference from the state git repo +# (which should be dropped to the AUR) + +> "${data_dir}/missing_state_file" +for pkgfile in `find "${packages_dir}" -type f -name PKGBUILD`; do + repo_in_pkgfile=`echo $pkgfile | rev | cut -f 2-3 -d / | rev` + state_file="${state_dir}/${repo_in_pkgfile}" + if test ! -f "${state_file}"; then + echo "${repo_in_pkgfile}\tnot in state repo anymore" >> "${data_dir}/missing_state_file" + fi +done +nof_missing_state_files=`cat ${data_dir}/missing_state_file | wc -l` +echo "missing_state_files\t${nof_missing_state_files}" >> "${data_dir}/stats" + +# find dangling references from the state repo not having a package repo + +> "${data_dir}/missing_package_repo" +for pkg in `find "${state_dir}"/{core,extra}-{any,x86_64} -type f | \ + rev | cut -f 1,2 -d / | rev | sort`; do + pkgfile_in_repo=`echo ${packages_dir}/${pkg}/PKGBUILD` + if test ! -f "${pkgfile_in_repo}"; then + echo "${pkg}\tno git repo" >> "${data_dir}/missing_package_repo" + fi +done + # TODO: update all single package directories # TODO: update all AUR package directories |