nitlanguage
/
nit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Java FFI: enable inserting additionnal Java files to a project
[nit.git]
/
src
/
modelbuilder.nit
diff --git
a/src/modelbuilder.nit
b/src/modelbuilder.nit
index
dc48ee9
..
85f9443
100644
(file)
--- a/
src/modelbuilder.nit
+++ b/
src/modelbuilder.nit
@@
-498,6
+498,16
@@
class ModelBuilder
mgroup = new MGroup(pn, parent.mproject, parent)
toolcontext.info("found sub group `{mgroup.full_name}` at {dirpath}", 2)
end
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
mgroup.filepath = dirpath
mgroups[rdp] = mgroup
return mgroup
@@
-616,7
+626,11
@@
class ModelBuilder
if decl != null then
var ndoc = decl.n_doc
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
end
return mmodule