Stow now only warns the user if a subdirectory when unstowing

This commit is contained in:
Guillaume Morin 2002-01-02 20:35:37 +00:00
parent dbf9ca6540
commit b3194c864e
2 changed files with 8 additions and 2 deletions

View file

@ -1,3 +1,8 @@
Wed Jan 02 21:33:41 2002 Guillaume Morin <gmorin@gnu.org>
* stow.in: Stow now only warns the user if a subdirectory
is unreadable during unstowing.
Wed Jan 02 20:58:05 2002 Guillaume Morin <gmorin@gnu.org> Wed Jan 02 20:58:05 2002 Guillaume Morin <gmorin@gnu.org>
* stow.in: fixed JoinPaths so that subdir called "0" are * stow.in: fixed JoinPaths so that subdir called "0" are

View file

@ -202,8 +202,9 @@ sub Unstow {
return (0, '') if (-e &JoinPaths($Target, $targetdir, '.stow')); return (0, '') if (-e &JoinPaths($Target, $targetdir, '.stow'));
warn sprintf("Unstowing in %s\n", &JoinPaths($Target, $targetdir)) warn sprintf("Unstowing in %s\n", &JoinPaths($Target, $targetdir))
if ($Verbose > 1); if ($Verbose > 1);
opendir(DIR, &JoinPaths($Target, $targetdir)) || if (!opendir(DIR, &JoinPaths($Target, $targetdir))) {
die "$ProgramName: Cannot read directory \"$dir\" ($!)\n"; warn "Warning: $ProgramName: Cannot read directory \"$dir\" ($!). Stow might leave some links. If you think, it does. Rerun Stow with appropriate rights.\n";
}
@contents = readdir(DIR); @contents = readdir(DIR);
closedir(DIR); closedir(DIR);
foreach $content (@contents) { foreach $content (@contents) {