src/Pure/Admin/build_doc.scala
changeset 72897 86eff7a823f3
parent 72854 6c660f05f70c
child 73340 0ffcad1f6130
equal deleted inserted replaced
72896:4e63acc435bd 72897:86eff7a823f3
    49     val errs =
    49     val errs =
    50       Par_List.map[(String, String), Option[String]](
    50       Par_List.map[(String, String), Option[String]](
    51       {
    51       {
    52         case (doc, session) =>
    52         case (doc, session) =>
    53           try {
    53           try {
    54             progress.echo("Documentation " + doc + " ...")
    54             progress.echo("Documentation " + quote(doc) + " ...")
    55 
    55 
    56             using(store.open_database_context())(db_context =>
    56             using(store.open_database_context())(db_context =>
    57               Presentation.build_documents(session, deps, db_context,
    57               Presentation.build_documents(session, deps, db_context,
    58                 output_pdf = Some(Path.explode("~~/doc"))))
    58                 output_pdf = Some(Path.explode("~~/doc"))))
    59             None
    59             None
    60           }
    60           }
    61           catch {
    61           catch {
    62             case Exn.Interrupt.ERROR(msg) =>
    62             case Exn.Interrupt.ERROR(msg) =>
    63               val sep = if (msg.contains('\n')) "\n" else " "
    63               val sep = if (msg.contains('\n')) "\n" else " "
    64               Some("Documentation " + doc + " failed:" + sep + msg)
    64               Some("Documentation " + quote(doc) + " failed:" + sep + msg)
    65           }
    65           }
    66       }, selected).flatten
    66       }, selected).flatten
    67 
    67 
    68     if (errs.nonEmpty) error(cat_lines(errs))
    68     if (errs.nonEmpty) error(cat_lines(errs))
    69   }
    69   }