diff options
author | Zac Medico <zmedico@gentoo.org> | 2017-09-20 11:11:53 -0700 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2017-09-20 11:13:44 -0700 |
commit | 5fc7281657e2a5a4b22e969853364b142a37d05f (patch) | |
tree | c3a3c11ef8521d70ce4d876043477f5c178b1c77 | |
parent | gnome2-utils postinst: fix ${missing} variable reference (diff) | |
download | portage-5fc7281657e2a5a4b22e969853364b142a37d05f.tar.gz portage-5fc7281657e2a5a4b22e969853364b142a37d05f.tar.bz2 portage-5fc7281657e2a5a4b22e969853364b142a37d05f.zip |
postinst-qa-check.d: remove redundant local vars and obsolete comments
Fixes: c4edb9ca3a6c ("postinst-qa-check.d: fix [[ ${files[@]} ]] logic in for loops")
Reported-by: Michał Górny <mgorny@gentoo.org>
-rw-r--r-- | bin/postinst-qa-check.d/50gnome2-utils | 4 | ||||
-rw-r--r-- | bin/postinst-qa-check.d/50xdg-utils | 8 |
2 files changed, 3 insertions, 9 deletions
diff --git a/bin/postinst-qa-check.d/50gnome2-utils b/bin/postinst-qa-check.d/50gnome2-utils index 7ee8f2528..569633fe3 100644 --- a/bin/postinst-qa-check.d/50gnome2-utils +++ b/bin/postinst-qa-check.d/50gnome2-utils @@ -1,7 +1,7 @@ # check for missing calls to gnome2-utils regen functions gnome2_icon_cache_check() { - local d f all_files=() find_args missing + local d f all_files=() missing for d in usr/share/icons/*/; do # gnome2_icon_cache_update updates only themes with an index [[ -f ${d}/index.theme ]] || continue @@ -24,8 +24,6 @@ gnome2_icon_cache_check() { # if any files were found, update the db to avoid repeating # the warning for subsequent packages - # (note: yes, it will eagerly repeat the update for next dirs - # but that's a minor issue) if [[ ${files[@]} ]]; then all_files+=("${files[@]}") addwrite "${d}" diff --git a/bin/postinst-qa-check.d/50xdg-utils b/bin/postinst-qa-check.d/50xdg-utils index ca4b49fe4..9164f8dc1 100644 --- a/bin/postinst-qa-check.d/50xdg-utils +++ b/bin/postinst-qa-check.d/50xdg-utils @@ -1,7 +1,7 @@ # check for missing calls to xdg-utils regen functions xdg_desktop_database_check() { - local d f files=() missing + local d f missing for d in usr/share/applications; do [[ -d ${d} ]] || continue @@ -20,8 +20,6 @@ xdg_desktop_database_check() { # if any files were found, update the db to avoid repeating # the warning for subsequent packages - # (note: yes, it will eagerly repeat the update for next dirs - # but it's a minor issue and we have only one dir anyway) if [[ ${files[@]} ]]; then all_files+=("${files[@]}") addwrite "${d}" @@ -41,7 +39,7 @@ xdg_desktop_database_check() { } xdg_mimeinfo_database_check() { - local d f files=() missing + local d f missing for d in usr/share/mime; do [[ -d ${d} ]] || continue @@ -57,8 +55,6 @@ xdg_mimeinfo_database_check() { # if any files were found, update the db to avoid repeating # the warning for subsequent packages - # (note: yes, it will eagerly repeat the update for next dirs - # but it's a minor issue and we have only one dir anyway) if [[ ${files[@]} ]]; then all_files+=("${files[@]}") addwrite "${d}" |