diff options
author | Guillaume Cottenceau <gc@mandriva.com> | 2003-11-03 21:01:40 +0000 |
---|---|---|
committer | Guillaume Cottenceau <gc@mandriva.com> | 2003-11-03 21:01:40 +0000 |
commit | bfb74f8e19dfb79be542b07cceffb48bb89eba09 (patch) | |
tree | bd1c218d189f1581d2d376a93560fabadf72bf02 /move/collect-directories-to-create.pl | |
parent | 6eb70d879ac65c1413ed84ba286f6123060a905e (diff) | |
download | drakx-bfb74f8e19dfb79be542b07cceffb48bb89eba09.tar drakx-bfb74f8e19dfb79be542b07cceffb48bb89eba09.tar.gz drakx-bfb74f8e19dfb79be542b07cceffb48bb89eba09.tar.bz2 drakx-bfb74f8e19dfb79be542b07cceffb48bb89eba09.tar.xz drakx-bfb74f8e19dfb79be542b07cceffb48bb89eba09.zip |
call summaryBefore to auto configure network, timezone, printers
obscure problems when launching foomatic-configure exhausted problem of missing subdirectories in /etc and /var, create them at startup when they are missing to prevent from future other problems of the kind
Diffstat (limited to 'move/collect-directories-to-create.pl')
-rwxr-xr-x | move/collect-directories-to-create.pl | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/move/collect-directories-to-create.pl b/move/collect-directories-to-create.pl new file mode 100755 index 000000000..c6e208c57 --- /dev/null +++ b/move/collect-directories-to-create.pl @@ -0,0 +1,17 @@ +#!/usr/bin/perl + +use strict; +use MDK::Common; + +#- there are programs/packages which fail when the directory +#- in which they try to write doesn't exist. better collect them +#- at build time so that drakx startup can create them. + +my @list = map { if_(m|^\Q$ARGV[0]\E(.*)$|, $1) } `find $ARGV[0]/{etc,var} -type d`; +my @final; +foreach my $e (sort { length($b) <=> length($a) } @list) { + any { /^\Q$e\E/ } @final and next; + push @final, $e; +} + +print "$_\n" foreach sort @final; |