src/Pure/Tools/doc.scala
changeset 52541 97c950217d7f
parent 52448 082a1c8c2c89
child 52542 19d674acb764
--- a/src/Pure/Tools/doc.scala	Sat Jul 06 21:50:14 2013 +0200
+++ b/src/Pure/Tools/doc.scala	Sat Jul 06 21:51:35 2013 +0200
@@ -18,7 +18,7 @@
     Path.split(Isabelle_System.getenv("ISABELLE_DOCS")).map(dir =>
       if (dir.is_dir) dir
       else error("Bad documentation directory: " + dir))
-
+    
 
   /* contents */
 
@@ -33,12 +33,21 @@
   sealed abstract class Entry
   case class Section(text: String) extends Entry
   case class Doc(name: String, title: String) extends Entry
+  case class Text_File(path: Path) extends Entry
 
   private val Section_Entry = new Regex("""^(\S.*)\s*$""")
   private val Doc_Entry = new Regex("""^\s+(\S+)\s+(.+)\s*$""")
 
+  private val release_notes =
+    List(Section("Release notes"),
+      Text_File(Path.explode("~~/ANNOUNCE")),
+      Text_File(Path.explode("~~/README")),
+      Text_File(Path.explode("~~/NEWS")),
+      Text_File(Path.explode("~~/COPYRIGHT")),
+      Text_File(Path.explode("~~/CONTRIBUTORS")))
+
   def contents(): List[Entry] =
-    for {
+    (for {
       line <- contents_lines()
       entry <-
         line match {
@@ -46,7 +55,7 @@
           case Doc_Entry(name, title) => Some(Doc(name, title))
           case _ => None
         }
-    } yield entry
+    } yield entry) ::: release_notes
 
 
   /* view */