[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master fcd9891 2/2: Use cached files instead of invo
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master fcd9891 2/2: Use cached files instead of invoking wget |
Date: |
Sun, 31 May 2020 09:34:19 -0400 (EDT) |
branch: master
commit fcd989169a3a645efee2298bd811a0137e1c77da
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>
Use cached files instead of invoking wget
The former use of 'mv' was too clever. The intermediate centos chroot
needs to keep the copies of dotfiles in its /tmp so that it can copy
them to /tmp in the chroot it creates.
---
lmi_setup_01c.sh | 11 ++++-------
lmi_setup_21.sh | 11 ++++-------
lmi_setup_42.sh | 2 +-
3 files changed, 9 insertions(+), 15 deletions(-)
diff --git a/lmi_setup_01c.sh b/lmi_setup_01c.sh
index 39bd121..3888d5a 100755
--- a/lmi_setup_01c.sh
+++ b/lmi_setup_01c.sh
@@ -35,8 +35,7 @@ assert_not_chrooted
# BEGIN ./lmi_setup_09.sh
# Configure zsh, for root and normal users.
-wget -N -nv "${GIT_URL_BASE}"/gwc/.zshrc
-mv .zshrc ~
+cp -a .zshrc ~
cp -a ~/.zshrc /home/"${NORMAL_USER}"/.zshrc
chown "${NORMAL_USER}":"${NORMAL_GROUP}" /home/"${NORMAL_USER}"/.zshrc
@@ -44,8 +43,7 @@ chown "${NORMAL_USER}":"${NORMAL_GROUP}"
/home/"${NORMAL_USER}"/.zshrc
# '~/.vimrc' and '/etc/vim/vimrc.local', use '~/.vimrc' for all
# customizations and copy that file for the normal user too.
-wget -N -nv "${GIT_URL_BASE}"/gwc/.vimrc
-mv .vimrc ~
+cp -a .vimrc ~
cp -a ~/.vimrc /home/"${NORMAL_USER}"/.vimrc
chown "${NORMAL_USER}":"${NORMAL_GROUP}" /home/"${NORMAL_USER}"/.vimrc
@@ -54,10 +52,9 @@ chown "${NORMAL_USER}":"${NORMAL_GROUP}"
/home/"${NORMAL_USER}"/.vimrc
mkdir ~/.vim
mkdir /home/"${NORMAL_USER}"/.vim
chown "${NORMAL_USER}":"${NORMAL_GROUP}" /home/"${NORMAL_USER}"/.vim
-# It's a much better idea to copy a mature spellfile hither:
-wget -N -nv "${GIT_URL_BASE}"/gwc/.vim/spell/en.utf-8.add
+# It's a much better idea to install a mature spellfile:
mkdir ~/.vim/spell
-mv en.utf-8.add ~/.vim/spell/en.utf-8.add
+cp -a en.utf-8.add ~/.vim/spell/en.utf-8.add
mkdir /home/"${NORMAL_USER}"/.vim/spell
chown "${NORMAL_USER}":"${NORMAL_GROUP}" /home/"${NORMAL_USER}"/.vim/spell
cp -a ~/.vim/spell/en.utf-8.add /home/"${NORMAL_USER}"/.vim/spell/en.utf-8.add
diff --git a/lmi_setup_21.sh b/lmi_setup_21.sh
index bb07589..98eb984 100755
--- a/lmi_setup_21.sh
+++ b/lmi_setup_21.sh
@@ -97,8 +97,7 @@ patch --dry-run --strip=0 --directory=/
</home/"${NORMAL_USER}"/ltmain.sh.patch
# BEGIN ./lmi_setup_09.sh
# Configure zsh, for root and normal users.
-wget -N -nv "${GIT_URL_BASE}"/gwc/.zshrc
-mv .zshrc ~
+cp -a .zshrc ~
cp -a ~/.zshrc /home/"${NORMAL_USER}"/.zshrc
chown "${NORMAL_USER}":"${NORMAL_GROUP}" /home/"${NORMAL_USER}"/.zshrc
@@ -106,8 +105,7 @@ chown "${NORMAL_USER}":"${NORMAL_GROUP}"
/home/"${NORMAL_USER}"/.zshrc
# '~/.vimrc' and '/etc/vim/vimrc.local', use '~/.vimrc' for all
# customizations and copy that file for the normal user too.
-wget -N -nv "${GIT_URL_BASE}"/gwc/.vimrc
-mv .vimrc ~
+cp -a .vimrc ~
cp -a ~/.vimrc /home/"${NORMAL_USER}"/.vimrc
chown "${NORMAL_USER}":"${NORMAL_GROUP}" /home/"${NORMAL_USER}"/.vimrc
@@ -116,10 +114,9 @@ chown "${NORMAL_USER}":"${NORMAL_GROUP}"
/home/"${NORMAL_USER}"/.vimrc
mkdir ~/.vim
mkdir /home/"${NORMAL_USER}"/.vim
chown "${NORMAL_USER}":"${NORMAL_GROUP}" /home/"${NORMAL_USER}"/.vim
-# It's a much better idea to copy a mature spellfile hither:
-wget -N -nv "${GIT_URL_BASE}"/gwc/.vim/spell/en.utf-8.add
+# It's a much better idea to install a mature spellfile:
mkdir ~/.vim/spell
-mv en.utf-8.add ~/.vim/spell/en.utf-8.add
+cp -a en.utf-8.add ~/.vim/spell/en.utf-8.add
mkdir /home/"${NORMAL_USER}"/.vim/spell
chown "${NORMAL_USER}":"${NORMAL_GROUP}" /home/"${NORMAL_USER}"/.vim/spell
cp -a ~/.vim/spell/en.utf-8.add /home/"${NORMAL_USER}"/.vim/spell/en.utf-8.add
diff --git a/lmi_setup_42.sh b/lmi_setup_42.sh
index 8cc82fc..ce68c9e 100755
--- a/lmi_setup_42.sh
+++ b/lmi_setup_42.sh
@@ -32,7 +32,7 @@ assert_chrooted
# Install lmi for wine.
cd ~ || { printf 'failed: cd\n'; exit 3; }
-wget -N -nv "${GIT_URL_BASE}"/install_msw.sh
+cp -a /tmp/install_msw.sh .
chmod +x install_msw.sh
logdir=/srv/cache_for_lmi/logs
mkdir -p "${logdir}"