diff options
author | Zac Medico <zmedico@gentoo.org> | 2010-12-13 20:29:10 -0800 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2010-12-14 06:28:31 -0800 |
commit | a729e9c5ac317e08625d8a62e1ba4794623ab2c9 (patch) | |
tree | 57a38672d878347dbcdc338b56bac016244941af | |
parent | 64247b288f3fb2e4cfb72e545ffc230e8a05dd74 (diff) | |
download | portage-a729e9c5ac317e08625d8a62e1ba4794623ab2c9.tar.gz portage-a729e9c5ac317e08625d8a62e1ba4794623ab2c9.tar.bz2 portage-a729e9c5ac317e08625d8a62e1ba4794623ab2c9.zip |
etc-update: eliminate duplicate example configs
-rwxr-xr-x | bin/etc-update | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/bin/etc-update b/bin/etc-update index d3b988ab6..e64ef493b 100755 --- a/bin/etc-update +++ b/bin/etc-update @@ -466,7 +466,11 @@ do_distconf() { suffix+="${count}" efile="${ofile}${suffix}" if [[ ! -f ${efile} ]]; then - mv ${mv_opts} ${file} ${efile} + mv ${mv_opts} "${file}" "${efile}" + break + elif diff_command "${file}" "${efile}" &> /dev/null; then + # replace identical copy + mv "${file}" "${efile}" break fi done |