carbon-config

config submodule of carbon-core-system
git clone https://ccx.te2000.cz/git/carbon-config
Log | Files | Refs

commit f92a7dfbc311cc9d8a17306d023dfaabd02de8f3
parent eb557869613604d8aec5504b39a91126c0491c9f
Author: Jan Pobrislo <ccx@webprojekty.cz>
Date:   Mon, 25 Jul 2022 10:22:11 +0200

Don't move away existing symlinks

Diffstat:
Mpostinstall | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/postinstall b/postinstall @@ -55,12 +55,12 @@ postinstall() { local diff_ret cd $ALL_DIR || exit $? ensure_symlink /command current/command || return $? - if [[ -f /etc/hostname ]]; then + if [[ ! -L /etc/hostname && -f /etc/hostname ]]; then mv /etc/hostname{,.orig.$EPOCHSECONDS} || exit $? fi ensure_symlink /etc/hostname ../current/conf/static/etc/hostname || return $? ensure_symlink /etc/profile.d/slashcommand.sh ../../current/conf/static/etc/profile.d/slashcommand.sh || return $? - if [[ -f /etc/mkinitfs/mkinitfs.conf ]]; then + if [[ ! -L /etc/mkinitfs/mkinitfs.conf && -f /etc/mkinitfs/mkinitfs.conf ]]; then mv /etc/mkinitfs/mkinitfs.conf{,.orig.$EPOCHSECONDS} || exit $? fi ensure_symlink /etc/mkinitfs/mkinitfs.conf ../../current/conf/static/etc/mkinitfs/mkinitfs.conf || return $?