Пример #1
0
 def pandoc(filename, source_filename):
     last_modified = release.last_modified(source_filename,
                                           self._in_docs_dir)
     variables = [
         ("last_modified_iso",
          time.strftime("%Y-%m-%d", last_modified)),
         ("last_modified_month_year",
          time.strftime("%B %Y", last_modified))]
     page_name = os.path.splitext(os.path.basename(filename))[0]
     variables.append(("nav", release.nav_html(site_map, page_name)))
     variables.append(("subnav", release.subnav_html(site_map,
                                                     page_name)))
     release.pandoc(self._in_docs_dir, filename, variables=variables)
Пример #2
0
 def pandoc(filename, source_filename):
     last_modified = release.last_modified(source_filename,
                                           self._in_docs_dir)
     if filename == "download.txt":
         last_modified = time.gmtime()
     variables = [("last_modified_iso",
                   time.strftime("%Y-%m-%d", last_modified)),
                  ("last_modified_month_year",
                   time.strftime("%B %Y", last_modified))]
     page_name = os.path.splitext(os.path.basename(filename))[0]
     variables.append(("nav", release.nav_html(site_map, page_name)))
     variables.append(
         ("subnav", release.subnav_html(site_map, page_name)))
     release.pandoc(self._in_docs_dir, filename, variables=variables)