<!--
Nick's web site: Intermediate document structure.
- Copyright © 2016-2018 Nick Bowler
+ Copyright © 2016-2020 Nick Bowler
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
%> <copyright><%= copyright %></copyright>
<% end
if @item[:license] then
- lic = find_license(@item[:license])
+ licref = @item[:license].split
+ lic = find_license(licref[0])
%> <license>
<identifier><%= File::basename(lic.identifier.without_ext) %></identifier>
- <name><%= lic[:title] %></name>
+ <name><%= [lic[:title], licref[1..-1]].compact.join(" ").strip %></name>
<uri><%= item_uri(lic) %></uri>
<modification-allowed><%=
lic[:"modification-allowed"] == true ? "yes" : "no"
</license>
<% end
%> <source>
+<% if @item.raw_filename %>
<file><%= item_source(@item) %></file>
- <revision><%= item.fetch(:gitrev) %></revision>
+<% elsif File.basename(@item.identifier) == "index.lst" %>
+ <dir><%= "content" + File.dirname(@item.identifier) %></dir>
+<% end %>
+ <revision><%= @item.fetch(:gitrev) %></revision>
<compiletime><%=
Time.now.gmtime.strftime "%Y-%m-%d %H:%M UTC"
%></compiletime>
</source>
- <html xmlns="<%= Xmlns['xhtml'] %>">
+ <hierarchy><% breadcrumbs_trail().compact.each do |item|
+ next if item == @item || item[:"breadcrumb-ignore"] %>
+ <parent>
+ <name><%=
+ if item == @items["/index.*"] then
+ "Entrance"
+ else
+ item[:title]
+ end
+ %></name>
+ <uri><%= item_uri(item) %></uri>
+ </parent><% end %>
+ </hierarchy>
+<% if @item[:kind] == "article" then
+%> <article>
+<%= attribute_to_time(@item[:published]).strftime \
+" <published>%Y-%m-%d</published>\n" if @item[:published]
+%> </article>
+<% end
+%> <html xmlns="<%= Xmlns['xhtml'] %>">
<% if !doc_header then
%> <h1><%= @item.fetch(:header, @item[:title]) %></h1>
<% end %><%= doc_str