wok rev 20095

slitaz-base-files: don't backup-restore the whole /etc ($CONFIG_FILES variable exist), allow to update /etc/init.d/rc.functions
author Aleksej Bobylev <al.bobylev@gmail.com>
date Thu Oct 05 23:51:00 2017 +0300 (2017-10-05)
parents 422e41a0b7ca
children c5ecec879e43
files slitaz-base-files/receipt
line diff
     1.1 --- a/slitaz-base-files/receipt	Thu Oct 05 15:35:01 2017 +0300
     1.2 +++ b/slitaz-base-files/receipt	Thu Oct 05 23:51:00 2017 +0300
     1.3 @@ -13,24 +13,28 @@
     1.4  
     1.5  DEPENDS="gettext-base"
     1.6  
     1.7 -CONFIG_FILES="
     1.8 -/etc/adduser.conf
     1.9 -/etc/passwd
    1.10 -/etc/fstab
    1.11 -/etc/issue
    1.12 -/etc/hosts
    1.13 -/etc/host.conf
    1.14 -/etc/hostname
    1.15 -/etc/group
    1.16 -/etc/gshadow
    1.17 -/etc/shadow
    1.18 -/etc/daemons.conf
    1.19 -/etc/nsswitch.conf
    1.20 -/etc/networks
    1.21 -/etc/profile
    1.22 -/etc/securetty
    1.23 -/etc/services
    1.24 -/etc/shells"
    1.25 +CONFIG_FILES="\
    1.26 +/etc/adduser.conf \
    1.27 +/etc/passwd \
    1.28 +/etc/fstab \
    1.29 +/etc/issue \
    1.30 +/etc/hosts \
    1.31 +/etc/host.conf \
    1.32 +/etc/hostname \
    1.33 +/etc/group \
    1.34 +/etc/gshadow \
    1.35 +/etc/shadow \
    1.36 +/etc/daemons.conf \
    1.37 +/etc/nsswitch.conf \
    1.38 +/etc/networks \
    1.39 +/etc/profile \
    1.40 +/etc/securetty \
    1.41 +/etc/services \
    1.42 +/etc/shells \
    1.43 +/etc/motd \
    1.44 +/etc/slitaz-release \
    1.45 +/etc/slitaz/slitaz.conf \
    1.46 +/etc/sysctl.conf"
    1.47  
    1.48  # Rules to configure and make the package.
    1.49  compile_rules()
    1.50 @@ -102,7 +106,7 @@
    1.51  #
    1.52  pre_install()
    1.53  {
    1.54 -	cp -a "$1/etc" "$1/tmp/etc.bak" 2>/dev/null
    1.55 +	# cp -a "$1/etc" "$1/tmp/etc.bak" 2>/dev/null
    1.56  	[ -x "$1/usr/bin/sudo" ] && mv "$1/usr/bin/sudo" "$1/usr/bin/sudo.orig"
    1.57  	# Remove old /var/run symlink
    1.58  	[ -h "$1/var/run" ] && rm -f "$1/var/run"
    1.59 @@ -111,9 +115,9 @@
    1.60  
    1.61  post_install()
    1.62  {
    1.63 -	if cp -a "$1/tmp/etc.bak"/* "$1/etc"; then
    1.64 -		rm -r "$1/tmp/etc.bak"
    1.65 -	fi 2>/dev/null
    1.66 +	# if cp -a "$1/tmp/etc.bak"/* "$1/etc"; then
    1.67 +	# 	rm -r "$1/tmp/etc.bak"
    1.68 +	# fi 2>/dev/null
    1.69  
    1.70  	[ -x "$1/usr/bin/sudo.orig" ] && mv -f "$1/usr/bin/sudo.orig" "$1/usr/bin/sudo"
    1.71