]> git.donarmstrong.com Git - debhelper.git/commitdiff
Support files with spaces in exclude mode. Closes: #459426
authorJoey Hess <joey@kodama.kitenet.net>
Mon, 7 Jan 2008 21:57:42 +0000 (16:57 -0500)
committerJoey Hess <joey@kodama.kitenet.net>
Mon, 7 Jan 2008 21:57:42 +0000 (16:57 -0500)
dh_installdocs
dh_installexamples

index 956a7fb801cd63f37fde895603e7bb03fdc01d7b..0350f870bc18a30956c216d06609ddd02021bf3c 100755 (executable)
@@ -136,10 +136,10 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
                            my ($dir_basename) = basename($doc);
                            my $pwd=`pwd`;
                            chomp $pwd;
-                           complex_doit("cd $doc/.. && find $dir_basename \\( -type f -or -type l \\)$exclude -exec cp --parents -dp {} $pwd/$tmp/usr/share/doc/$package \\;");
+                           complex_doit("cd '$doc/..' && find '$dir_basename' \\( -type f -or -type l \\)$exclude -exec cp --parents -dp {} $pwd/$tmp/usr/share/doc/$package \\;");
                        }
                        else {
-                               doit("cp","-a",$doc,"$tmp/usr/share/doc/$package");
+                               doit("cp", "-a", $doc, "$tmp/usr/share/doc/$package");
                        }
                }
                doit("chown","-R","0:0","$tmp/usr/share/doc");
index dcd37ad5a08315084b241f0493274767c50530fb..0f3651cfa85c68dd5277164219ffbd89c038ce9a 100755 (executable)
@@ -87,10 +87,9 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
                        next if excludefile($example);
                        if (-d $example && $exclude) {
                                my ($dir_basename) = basename($example);
-                               # Pity there's no cp --exclude ..
                                my $pwd=`pwd`;
                                chomp $pwd;
-                               complex_doit("cd $example/.. && find $dir_basename -type f$exclude -exec cp --parents -dp {} $pwd/$tmp/usr/share/doc/$package/examples \\;");
+                               complex_doit("cd '$example/..' && find '$dir_basename' -type f$exclude -exec cp --parents -dp {} $pwd/$tmp/usr/share/doc/$package/examples \\;");
                        }
                        else {
                                doit("cp", "-a", $example, "$tmp/usr/share/doc/$package/examples");