<% if page.data.xsl.present? %> <% end %> <% output_collection_names = site.config.collections.select { |_name, data| data.output }.keys %> <% collections.slice(*output_collection_names).each do |_name, collection| %> <% collection.resources.each do |resource| %> <% next if resource.id == "/404" || resource.data.sitemap == false %> <%= xml_escape resource.absolute_url %> <%= resource.sitemap_last_modified_at.localtime.xmlschema %> <% if resource.data.sitemap_priority %> <%= resource.data.sitemap_priority %> <% end %> <% if resource.data.sitemap_change_frequency %> <%= resource.data.sitemap_change_frequency %> <% end %> <% end %> <% end %> <% site.generated_pages.each do |generated_page| %> <% next if ["sitemap.erb", "robots.liquid"].include? generated_page.name %> <% next if generated_page.data.sitemap == false %> <%= xml_escape absolute_url(generated_page.url) %> <%= (generated_page.data.last_modified_at || site.time).localtime.xmlschema %> <% if generated_page.data.sitemap_priority %> <%= generated_page.data.sitemap_priority %> <% end %> <% if generated_page.data.sitemap_change_frequency %> <%= generated_page.data.sitemap_change_frequency %> <% end %> <% end %> <% page.data.static_files.each do |file| %> <% next if file.data.sitemap == false %> <%= xml_escape absolute_url(file.relative_path) %> <%= file.modified_time.localtime.xmlschema %> <% if file.data.sitemap_priority %> <%= file.data.sitemap_priority %> <% end %> <% if file.data.sitemap_change_frequency %> <%= file.data.sitemap_change_frequency %> <% end %> <% end %>