mgroup = new MGroup(pn, parent.mproject, parent)
toolcontext.info("found sub group `{mgroup.full_name}` at {dirpath}", 2)
end
+ var readme = dirpath.join_path("README")
+ if readme.file_exists then
+ var mdoc = new MDoc
+ var s = new IFStream.open(readme)
+ while not s.eof do
+ mdoc.content.add(s.read_line)
+ end
+ mgroup.mdoc = mdoc
+ mdoc.original_mentity = mgroup
+ end
mgroup.filepath = dirpath
mgroups[rdp] = mgroup
return mgroup
if decl != null then
var ndoc = decl.n_doc
- if ndoc != null then mmodule.mdoc = ndoc.to_mdoc
+ if ndoc != null then
+ var mdoc = ndoc.to_mdoc
+ mmodule.mdoc = mdoc
+ mdoc.original_mentity = mmodule
+ end
end
return mmodule