Skip to content

Commit

Permalink
improve error message when template not found
Browse files Browse the repository at this point in the history
  • Loading branch information
kristoff-it committed Aug 29, 2024
1 parent 65b5456 commit ff9ec8a
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/exes/layout.zig
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,17 @@ pub fn main() !void {
log.debug("loading template = '{s}'", .{template_path});
const template_html = readFile(build_root, template_path, arena) catch |ioerr| {
super_vm.reportResourceFetchError(@errorName(ioerr));
std.debug.print(
\\
\\NOTE: Zine expects templates to be placed under a
\\ 'templates/' subdirectory in your layouts
\\ directory.
\\
\\Zine tried to find the template here:
\\'{s}'
\\
\\
, .{template_path});
std.process.exit(1);
};

Expand Down

0 comments on commit ff9ec8a

Please sign in to comment.