dbdiff: Check if the files exist before starting to compare them.
Warning, cannot access the index:
_darcs/index: opening of '_darcs/index' failed: permission denied (Permission denied)
diff -rN -u old-bii_scripts/bin/dbdiff new-bii_scripts/bin/dbdiff
--- old-bii_scripts/bin/dbdiff 2022-12-09 19:23:40.865768807 +0100
+++ new-bii_scripts/bin/dbdiff 2022-12-09 19:23:40.865768807 +0100
@@ -80,6 +80,16 @@
my $f2= shift @ARGV;
die "second filename is missing" if (!defined $f2);
+if (! -e $f1)
+ {
+ die "file '$f1' doesn't exist\n";
+ };
+if (! -e $f2)
+ {
+ die "file '$f2' doesn't exist\n";
+ };
+
+
if ((defined $opt_parse) || defined ($opt_parse_table))
{
parse_diff($opt_parse_table, $opt_name_regexp, $f1,$f2);
patch 7a623e99968dbbc602f9c07d86a0a1ce55daca75
Author: Goetz.Pfeiffer@helmholtz-berlin.de
Date: Fri Mar 12 14:16:43 CET 2021
* dbdiff: Check if the files exist before starting to compare them