home · contact · privacy
More fixes. master
authorChristian Heller <c.heller@plomlompom.de>
Wed, 23 Oct 2024 04:20:26 +0000 (06:20 +0200)
committerChristian Heller <c.heller@plomlompom.de>
Wed, 23 Oct 2024 04:20:26 +0000 (06:20 +0200)
many_releases/scripts/_misc.sh
testing/scripts/setup_raspi.sh

index c25a291f6a82a5e7ea3f064da33dbf0a25aabb89..d1aa60684c368d80822769c71f6989b30078b5c8 100755 (executable)
@@ -27,6 +27,7 @@ copy_dirtree() {
     target_root="$2"
     shift 2
     modules="$@"
     target_root="$2"
     shift 2
     modules="$@"
+    initial_directory="$(pwd)"
     for module in "${modules}"; do
         mkdir -p "${source_root}/${module}"
         cd "${source_root}/${module}"
     for module in "${modules}"; do
         mkdir -p "${source_root}/${module}"
         cd "${source_root}/${module}"
@@ -38,6 +39,7 @@ copy_dirtree() {
             cp "${source_path}" "${target_path}"
         done
     done
             cp "${source_path}" "${target_path}"
         done
     done
+    cd "${initial_directory}"
 }
 
 install_for_modules() {
 }
 
 install_for_modules() {
index d3304cf0a9c0a8ea11759afc64ada51a534dbada..84c3f8a4989525d625aea73215d967e0c03a53ae 100755 (executable)
@@ -14,12 +14,12 @@ rm "${FILENAME_PUBLIC_KEY}"
 # service sshd restart
 
 # properly apt system
 # service sshd restart
 
 # properly apt system
-for root in "${PATH_MANY}" '../'; do
+for root in "${PATH_MANY}" '..'; do
     copy_dirtree "${root}/${NAME_ETC_DIR}" "" all
 done
 apt update
 mark_nonrequireds_auto
     copy_dirtree "${root}/${NAME_ETC_DIR}" "" all
 done
 apt update
 mark_nonrequireds_auto
-for root in "${PATH_MANY}" '../'; do
+for root in "${PATH_MANY}" '..'; do
     install_for_modules "${root}/${NAME_APTMARK_DIR}" all
 done
 apt -y --purge autoremove
     install_for_modules "${root}/${NAME_APTMARK_DIR}" all
 done
 apt -y --purge autoremove
@@ -33,7 +33,7 @@ apt -y -o Dpkg::Options::='--force-confnew' full-upgrade
 # ln -sf /usr/share/zoneinfo/Europe/Berlin /etc/localtime
 
 # Set up users and their environments.
 # ln -sf /usr/share/zoneinfo/Europe/Berlin /etc/localtime
 
 # Set up users and their environments.
-for root in "${PATH_MANY}" '../'; do
+for root in "${PATH_MANY}" '..'; do
     copy_dirtree "${root}/${NAME_HOME_DIR}" '/root' minimal root
 done
 adduser --disabled-password --gecos "" plom
     copy_dirtree "${root}/${NAME_HOME_DIR}" '/root' minimal root
 done
 adduser --disabled-password --gecos "" plom