ikiwiki/doc/patchqueue/better_error_in_srcfile.mdwn

17 lines
604 B
Plaintext
Raw Normal View History

Just a one-liner patch to make srcfile more descriptive when it fails. --Ethan
<pre>
Index: IkiWiki.pm
===================================================================
--- IkiWiki.pm (revision 3194)
+++ IkiWiki.pm (working copy)
@@ -247,7 +247,7 @@
return "$config{srcdir}/$file" if -e "$config{srcdir}/$file";
return "$config{underlaydir}/$file" if -e "$config{underlaydir}/$file";
- error("internal error: $file cannot be found");
+ error("internal error: $file cannot be found in $config{srcdir} or $config{underlaydir}");
} #}}}
sub readfile ($;$$) { #{{{
</pre>