diff options
author | scrappy <scrappy@FreeBSD.org> | 2006-04-16 00:23:50 +0800 |
---|---|---|
committer | scrappy <scrappy@FreeBSD.org> | 2006-04-16 00:23:50 +0800 |
commit | 4ef678cedbb4c3da06124e9d9a32e2c1e2374fa5 (patch) | |
tree | edbfa1dc81432dd1fbd6551821fba5553f2798c1 /www/horde-base | |
parent | 2899b20061336fe346fe998f1cbe0d0389ff3022 (diff) | |
download | freebsd-ports-gnome-4ef678cedbb4c3da06124e9d9a32e2c1e2374fa5.tar.gz freebsd-ports-gnome-4ef678cedbb4c3da06124e9d9a32e2c1e2374fa5.tar.zst freebsd-ports-gnome-4ef678cedbb4c3da06124e9d9a32e2c1e2374fa5.zip |
After a recent discussion on freebsd-ports, I have modified the Horde
ports, so that they now do not overwrite existing configuration files.
Rather than backing up the old ones and allowing the user to merge the
files by hand, config files are left untouched.
Submitted by: Shaun Amott <shaun@inerd.com>
Diffstat (limited to 'www/horde-base')
-rw-r--r-- | www/horde-base/files/pkg-deinstall.in | 9 | ||||
-rw-r--r-- | www/horde-base/files/pkg-install.in | 13 | ||||
-rw-r--r-- | www/horde-base/files/pkg-message.in | 5 |
3 files changed, 9 insertions, 18 deletions
diff --git a/www/horde-base/files/pkg-deinstall.in b/www/horde-base/files/pkg-deinstall.in index 47cbca9552a2..7f9f6649e9fa 100644 --- a/www/horde-base/files/pkg-deinstall.in +++ b/www/horde-base/files/pkg-deinstall.in @@ -22,13 +22,10 @@ handle_config() { for cf in `ls %%HORDEDIR%%/config/*php`; do diff -bBqw $cf $cf.dist >/dev/null 2>&1 case $? in - 0) # original config file, will be deleted by pkg-plist + 0) # original config file, delete + rm -f $cf ;; - 1) # config file has been updated, must be backuped - cp -p $cf $cf.previous - echo "===> Backing-up..." - echo "---> $cf has been saved ***" - echo "---> as $cf.previous ***" + 1) # config file has been updated, leave it ;; *) # not found? ;; diff --git a/www/horde-base/files/pkg-install.in b/www/horde-base/files/pkg-install.in index 28db88333734..a2dc1e225389 100644 --- a/www/horde-base/files/pkg-install.in +++ b/www/horde-base/files/pkg-install.in @@ -102,14 +102,11 @@ case $2 in fi if [ -z "${PACKAGE_BUILDING}" ]; then - # Don't reset the config to default (PR ports/88621) - - for cf in `ls %%HORDEDIR%%/config/*php`; do - if [ -f $cf.previous ]; then - mv $cf $cf.new - echo "---> $cf not installed ***" - echo "---> please copy from $cf.previous ***" - echo "---> or from $cf.new ***" + # Copy over sample config files unless they already exist + + for cf in `ls %%HORDEDIR%%/config/*.dist | sed -e 's/\.dist//g'`; do + if [ ! -f $cf ]; then + cp -p $cf.dist $cf fi done fi diff --git a/www/horde-base/files/pkg-message.in b/www/horde-base/files/pkg-message.in index c5a0ca6935e5..3226c28ff455 100644 --- a/www/horde-base/files/pkg-message.in +++ b/www/horde-base/files/pkg-message.in @@ -1,9 +1,6 @@ ************************************************************************ Horde has been installed in %%HORDEDIR%% with your blank -configuration files. After a reinstallation, you have to explicitely -merge your files %%HORDEDIR%%/config/conf.php.new -and %%HORDEDIR%%/config/conf.php.previous -into %%HORDEDIR%%/config/conf.php . +configuration files. WARNING! the first user will get logged in as an administrator! ******** |