]> Frank Brehm's Git Trees - pixelpark/create-vmware-tpl.git/commitdiff
Bugfixing snippets/tpl.100.clear_repos.sh
authorFrank Brehm <frank.brehm@pixelpark.com>
Fri, 19 Jun 2020 08:40:21 +0000 (10:40 +0200)
committerFrank Brehm <frank.brehm@pixelpark.com>
Fri, 19 Jun 2020 08:40:21 +0000 (10:40 +0200)
snippets/tpl.100.clear_repos.sh

index f20c15e5b602c77913ccd4dac2fc56bd30657093..a638d2c1938f0d7a620e65f759ee9454c8ba0b16 100644 (file)
@@ -12,7 +12,6 @@ clear_all_repo_files() {
     local repo_dir="/etc/yum.repos.d"
     local old_dir="${repo_dir}/.old"
     local repo_file=
-    local bname=
 
     mkdir -pv "${old_dir}"
 
@@ -20,8 +19,7 @@ clear_all_repo_files() {
         if [[ ! -f "${repo_file}" ]] ; then
             continue
         fi
-        bname=$( echo "${repo_file}" | basename )
-        echo " - ${bname}"
+        echo " - $( basename "${repo_file}" )"
         cp -pv "${repo_file}" "${old_dir}"
         cp -v /dev/null "${repo_file}"
     done