From 9664bee729d487bcc0a0bc35859f8e13d5421c75 Mon Sep 17 00:00:00 2001 From: Patrick J Volkerding Date: Wed, 26 Sep 2012 01:10:42 +0000 Subject: Slackware 14.0 Wed Sep 26 01:10:42 UTC 2012 Slackware 14.0 x86_64 stable is released! We're perfectionists here at Slackware, so this release has been a long time a-brewing. But we think you'll agree that it was worth the wait. Slackware 14.0 combines modern components, ease of use, and flexible configuration... our "KISS" philosophy demands it. The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware project by picking up a copy from store.slackware.com. We're taking pre-orders now, and offer a discount if you sign up for a subscription. Thanks to everyone who helped make this happen. The Slackware team, the upstream developers, and (of course) the awesome Slackware user community. Have fun! :-) --- source/n/NetworkManager/doinst.sh | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 source/n/NetworkManager/doinst.sh (limited to 'source/n/NetworkManager/doinst.sh') diff --git a/source/n/NetworkManager/doinst.sh b/source/n/NetworkManager/doinst.sh new file mode 100644 index 00000000..2b419b26 --- /dev/null +++ b/source/n/NetworkManager/doinst.sh @@ -0,0 +1,32 @@ +config() { + NEW="$1" + OLD="$(dirname $NEW)/$(basename $NEW .new)" + # If there's no config file by that name, mv it over: + if [ ! -r $OLD ]; then + mv $NEW $OLD + elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then + # toss the redundant copy + rm $NEW + fi + # Otherwise, we leave the .new copy for the admin to consider... +} + +preserve_perms() { + NEW="$1" + OLD="$(dirname ${NEW})/$(basename ${NEW} .new)" + if [ -e ${OLD} ]; then + cp -a ${OLD} ${NEW}.incoming + cat ${NEW} > ${NEW}.incoming + mv ${NEW}.incoming ${NEW} + fi + config ${NEW} +} + +if [ -e etc/HOSTNAME ]; then + sed -i "s,yourhostname,$(cat etc/HOSTNAME | cut -f1 -d .)," \ + etc/NetworkManager/NetworkManager.conf.new +fi + +preserve_perms etc/rc.d/rc.networkmanager.new +config etc/NetworkManager/NetworkManager.conf.new + -- cgit v1.2.3