[Box Backup-dev] makeparcels.pl - check for directory

Stefan Norlin boxbackup-dev at fluffy.co.uk
Wed Feb 1 07:59:58 GMT 2006


Hi,

I have not taken any active part in development (yet) but I have
a suggestion for a very small change when generating the makefile.

Check for directory before it is created as indicated below.

Cheers,
Stefan

Index: infrastructure/makeparcels.pl
===================================================================
--- infrastructure/makeparcels.pl       (revision 354)
+++ infrastructure/makeparcels.pl       (working copy)
@@ -104,7 +104,7 @@
        print MAKE $target,":\n";

        my $dir = parcel_dir($parcel);
-       print MAKE "\tmkdir $dir\n";
+       print MAKE "\t[ -d $dir ] || mkdir $dir\n";

        open SCRIPT,">parcels/scripts/install-$parcel" or die "Can't open 
installer script for $parcel for writing";
        print SCRIPT "#!/bin/sh\n\n";




More information about the Boxbackup-dev mailing list