aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <waruqi@gmail.com>2019-05-13 22:56:15 +0800
committerruki <waruqi@gmail.com>2019-05-13 11:37:34 +0800
commitced9fbfb71fcffc8d9286b20dbd0b921ff09d41c (patch)
tree26e31dc188f00317602396b9c6b058096bf8c5f5
parent8334850371c950c61cd91085c80b34dc79f38155 (diff)
downloadxmake-docs-ced9fbfb71fcffc8d9286b20dbd0b921ff09d41c.tar.gz
xmake-docs-ced9fbfb71fcffc8d9286b20dbd0b921ff09d41c.zip
modify docs
-rw-r--r--manual.md8
-rw-r--r--zh/manual.md8
2 files changed, 16 insertions, 0 deletions
diff --git a/manual.md b/manual.md
index c3bdb388..c8c10b72 100644
--- a/manual.md
+++ b/manual.md
@@ -457,6 +457,10 @@ set_xmakever("2.1.0")
###### Add sub-project directories
+<p class="tips">
+For xmake 2.x and above, try to use the [includes](#includes) interface, which is a generic version of add_subdirs and add_subfiles, and supports some built-in extensions.
+</p>
+
This interface will add sub-project directories to the current `xmake.lua`, it will load the `xmake.lua` file of the sub-directories.
For example, assume we have the following project directory tree:
@@ -491,6 +495,10 @@ $ xmake build tbox
###### Add sub-project files
+<p class="tips">
+For xmake 2.x and above, try to use the [includes](#includes) interface, which is a generic version of add_subdirs and add_subfiles, and supports some built-in extensions.
+</p>
+
`add_subfiles` is similar to [add_subdirs](#add_subdirs).
The only difference is that this interface specifies the path to the 'xmake.lua' file directly, rather than a directory.
diff --git a/zh/manual.md b/zh/manual.md
index c0cb1373..a1005fae 100644
--- a/zh/manual.md
+++ b/zh/manual.md
@@ -478,6 +478,10 @@ set_xmakever("2.1.0")
###### 添加子工程目录
+<p class="tips">
+xmake 2.x以上版本,请尽量使用[includes](#includes)这个接口,这个是add_subdirs和add_subfiles的通用版本,并且支持一些内建扩展模块。
+</p>
+
每个子工程对应一个`xmake.lua`的工程描述文件。
虽然一个`xmake.lua`也可以描述多个子工程模块,但是如果工程越来越大,越来越复杂,适当的模块化是很有必要的。。
@@ -519,6 +523,10 @@ $ xmake build tbox
###### 添加子工程文件
+<p class="tips">
+xmake 2.x以上版本,请尽量使用[includes](#includes)这个接口,这个是add_subdirs和add_subfiles的通用版本,并且支持一些内建扩展模块。
+</p>
+
`add_subfiles`的作用与[add_subdirs](#add_subdirs)类似,唯一的区别就是:这个接口直接指定`xmake.lua`文件所在的路径,而不是目录,例如:
```lua