diff options
| author | ruki <[email protected]> | 2017-07-20 17:17:58 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2017-07-20 17:17:58 +0800 |
| commit | be78dc55d571e152cfc8abf69b60b9e207539768 (patch) | |
| tree | 1bd67ae334fc5a6e58a47a2e6e9f720ef722f263 | |
| parent | b0eeeda1f43bf10f52069d2ab8fd651b164b70ea (diff) | |
move some plugins to xmake-plugins repo
| -rw-r--r-- | CHANGELOG.md | 2 | ||||
| -rw-r--r-- | README.md | 5 | ||||
| -rw-r--r-- | README_zh.md | 5 | ||||
| -rw-r--r-- | docs/cn/index.html | 9 | ||||
| -rw-r--r-- | docs/landing.html | 5 | ||||
| -rw-r--r-- | docs/landing/index.cn.md | 5 | ||||
| -rw-r--r-- | docs/landing/index.md | 5 | ||||
| -rw-r--r-- | docs/plugins.md | 4 | ||||
| -rw-r--r-- | docs/zh/plugins.md | 4 | ||||
| -rw-r--r-- | xmake/plugins/app2ipa/main.lua | 83 | ||||
| -rw-r--r-- | xmake/plugins/app2ipa/xmake.lua | 50 | ||||
| -rw-r--r-- | xmake/plugins/echo/xmake.lua | 76 |
12 files changed, 36 insertions, 217 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 3e96d687b..bc894321b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -38,6 +38,7 @@ * Mark `add_bindings` and `add_rbindings` as deprecated * Optimize `xmake rebuild` speed on windows * Move `core.project.task` to `core.base.task` +* Move `echo` and `app2ipa` plugins to [xmake-plugins](https://github.com/tboox/xmake-plugins) repo. ### Bugs fixed @@ -352,6 +353,7 @@ * 标记`add_bindings`和`add_rbindings`为废弃接口 * 优化`xmake rebuild`在windows上的构建速度 * 将`core.project.task`模块迁移至`core.base.task` +* 将`echo` 和 `app2ipa` 插件迁移到 [xmake-plugins](https://github.com/tboox/xmake-plugins) 仓库 ### Bugs修复 @@ -131,7 +131,10 @@ $ xmake run -d console * Run the custom lua script plugin * Generate IDE project file plugin(makefile, vs2002 - vs2017 .. ) * Generate doxygen document plugin -* Convert .app to .ipa plugin + +## More Plugins + +Please download and install from the plugins repository [xmake-plugins](https://github.com/tboox/xmake-plugins). ## Examples diff --git a/README_zh.md b/README_zh.md index 7dd2ed0ef..5e8145253 100644 --- a/README_zh.md +++ b/README_zh.md @@ -137,7 +137,10 @@ $ xmake run -d console * 加载自定义lua脚本插件 * 生成IDE工程文件插件(makefile, vs2002 - vs2017, ...) * 生成doxygen文档插件 -* iOS app2ipa插件 + +## 更多插件 + +请到插件仓库进行下载安装: [xmake-plugins](https://github.com/tboox/xmake-plugins). ## 简单例子 diff --git a/docs/cn/index.html b/docs/cn/index.html index ec25b2141..aba3789a5 100644 --- a/docs/cn/index.html +++ b/docs/cn/index.html @@ -137,14 +137,17 @@ <li>加载自定义lua脚本插件</li> <li>生成IDE工程文件插件(makefile, vs2002 - vs2017, …)</li> <li>生成doxygen文档插件</li> - <li>iOS app2ipa插件</li> </ul> -<h2 id="section-9">使用演示</h2> +<h2 id="section-9">更多插件</h2> + +<p>请到插件仓库进行下载安装: <a href="https://github.com/tboox/xmake-plugins">xmake-plugins</a>.</p> + +<h2 id="section-10">使用演示</h2> <p><a href="https://github.com/tboox/xmake"><img src="http://tboox.org/static/img/xmake/build_demo.gif" alt="usage_demo" /></a></p> -<h2 id="section-10">联系方式</h2> +<h2 id="section-11">联系方式</h2> <ul> <li>邮箱:<a href="mailto:[email protected]">[email protected]</a></li> diff --git a/docs/landing.html b/docs/landing.html index 6b01de784..e3d679daf 100644 --- a/docs/landing.html +++ b/docs/landing.html @@ -137,9 +137,12 @@ <li>Run the custom lua script plugin</li> <li>Generate IDE project file plugin(makefile, vs2002 - vs2017 .. )</li> <li>Generate doxygen document plugin</li> - <li>Convert .app to .ipa plugin</li> </ul> +<h2 id="more-plugins">More Plugins</h2> + +<p>Please download and install from the plugins repository <a href="https://github.com/tboox/xmake-plugins">xmake-plugins</a>.</p> + <h2 id="examples">Examples</h2> <p><a href="https://github.com/tboox/xmake"><img src="http://tboox.org/static/img/xmake/build_demo.gif" alt="usage_demo" /></a></p> diff --git a/docs/landing/index.cn.md b/docs/landing/index.cn.md index d8297edaa..949cd581f 100644 --- a/docs/landing/index.cn.md +++ b/docs/landing/index.cn.md @@ -84,7 +84,10 @@ $ xmake run -d console * 加载自定义lua脚本插件 * 生成IDE工程文件插件(makefile, vs2002 - vs2017, ...) * 生成doxygen文档插件 -* iOS app2ipa插件 + +## 更多插件 + +请到插件仓库进行下载安装: [xmake-plugins](https://github.com/tboox/xmake-plugins). ## 使用演示 diff --git a/docs/landing/index.md b/docs/landing/index.md index de491978c..2ac8b0e96 100644 --- a/docs/landing/index.md +++ b/docs/landing/index.md @@ -84,7 +84,10 @@ $ xmake run -d console * Run the custom lua script plugin * Generate IDE project file plugin(makefile, vs2002 - vs2017 .. ) * Generate doxygen document plugin -* Convert .app to .ipa plugin + +## More Plugins + +Please download and install from the plugins repository [xmake-plugins](https://github.com/tboox/xmake-plugins). ## Examples diff --git a/docs/plugins.md b/docs/plugins.md index 8091f1456..fe0981f13 100644 --- a/docs/plugins.md +++ b/docs/plugins.md @@ -466,6 +466,10 @@ Please ensure that the doxygen tool has been installed first. $ xmake doxygen ``` +## More Plugins + +Please download and install from the plugins repository [xmake-plugins](https://github.com/tboox/xmake-plugins). + #### Convert .app to .ipa ```bash diff --git a/docs/zh/plugins.md b/docs/zh/plugins.md index 2988fdb59..13eaa5432 100644 --- a/docs/zh/plugins.md +++ b/docs/zh/plugins.md @@ -490,6 +490,10 @@ set_modes("debug", "release") $ xmake doxygen ``` +## 更多插件 + +请到插件仓库进行下载安装: [xmake-plugins](https://github.com/tboox/xmake-plugins). + #### 从app生成ipa包 这仅仅是一个小插件,ios开发的同学,可能会用的到。 diff --git a/xmake/plugins/app2ipa/main.lua b/xmake/plugins/app2ipa/main.lua deleted file mode 100644 index f03657b70..000000000 --- a/xmake/plugins/app2ipa/main.lua +++ /dev/null @@ -1,83 +0,0 @@ ---!The Make-like Build Utility based on Lua --- --- Licensed to the Apache Software Foundation (ASF) under one --- or more contributor license agreements. See the NOTICE file --- distributed with this work for additional information --- regarding copyright ownership. The ASF licenses this file --- to you under the Apache License, Version 2.0 (the --- "License"); you may not use this file except in compliance --- with the License. You may obtain a copy of the License at --- --- http://www.apache.org/licenses/LICENSE-2.0 --- --- Unless required by applicable law or agreed to in writing, software --- distributed under the License is distributed on an "AS IS" BASIS, --- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --- See the License for the specific language governing permissions and --- limitations under the License. --- --- Copyright (C) 2015 - 2017, TBOOX Open Source Group. --- --- @author ruki --- @file main.lua --- - --- imports -import("core.base.option") -import("detect.tools.find_zip") - --- main -function main() - - -- find zip - local zip = find_zip() - assert(zip, "zip not found!") - - -- get the .app file path - local app = option.get("app") - assert(app, "please input the .app path!") - assert(os.isdir(app), "%s not found!", app) - - -- get the app name - local appname = path.basename(app) - - -- get the .ipa file path - local ipa = option.get("ipa") - if not ipa then - ipa = path.join(path.directory(app), appname .. ".ipa") - end - - -- get icon file path - local icon = option.get("icon") - assert(icon, "please input the icon path!") - assert(os.isfile(icon), "%s not found!", icon) - - -- the temporary directory - local tmpdir = path.join(os.tmpdir(), "app2ipa", appname) - - -- clean the tmpdir first - os.rm(tmpdir) - - -- make the payload directory - os.mkdir(path.join(tmpdir, "Payload")) - - -- copy the .app directory into payload - os.cp(app, path.join(tmpdir, "Payload")) - - -- copy icon to iTunesArtwork - os.cp(icon, path.join(tmpdir, "iTunesArtwork")) - - -- generate .ipa file - os.cd(tmpdir) - os.run("%s -r %s Payload iTunesArtwork", zip, ipa) - os.cd("-") - - -- remove the temporary directory - os.rm(tmpdir) - - -- check - assert(os.isfile(ipa), "generate %s failed!", ipa) - - -- trace - cprint("${bright}generate %s ok!${ok_hand}", ipa) -end diff --git a/xmake/plugins/app2ipa/xmake.lua b/xmake/plugins/app2ipa/xmake.lua deleted file mode 100644 index f2ee42be1..000000000 --- a/xmake/plugins/app2ipa/xmake.lua +++ /dev/null @@ -1,50 +0,0 @@ ---!The Make-like Build Utility based on Lua --- --- Licensed to the Apache Software Foundation (ASF) under one --- or more contributor license agreements. See the NOTICE file --- distributed with this work for additional information --- regarding copyright ownership. The ASF licenses this file --- to you under the Apache License, Version 2.0 (the --- "License"); you may not use this file except in compliance --- with the License. You may obtain a copy of the License at --- --- http://www.apache.org/licenses/LICENSE-2.0 --- --- Unless required by applicable law or agreed to in writing, software --- distributed under the License is distributed on an "AS IS" BASIS, --- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --- See the License for the specific language governing permissions and --- limitations under the License. --- --- Copyright (C) 2015 - 2017, TBOOX Open Source Group. --- --- @author ruki --- @file app2ipa.lua --- - --- define task -task("app2ipa") - - -- set category - set_category("plugin") - - -- on run - on_run("main") - - -- set menu - set_menu { - -- usage - usage = "xmake app2ipa [options] xxx.app" - - -- description - , description = "Generate .ipa file from the given .app" - - -- options - , options = - { - {'o', "ipa", "kv", nil, "Set the .ipa file path." } - , {nil, "icon", "kv", nil, "Set the icon file path." } - , {} - , {nil, "app", "v", nil, "Set the .app directory." } - } - } diff --git a/xmake/plugins/echo/xmake.lua b/xmake/plugins/echo/xmake.lua deleted file mode 100644 index a593a9f82..000000000 --- a/xmake/plugins/echo/xmake.lua +++ /dev/null @@ -1,76 +0,0 @@ ---!The Make-like Build Utility based on Lua --- --- Licensed to the Apache Software Foundation (ASF) under one --- or more contributor license agreements. See the NOTICE file --- distributed with this work for additional information --- regarding copyright ownership. The ASF licenses this file --- to you under the Apache License, Version 2.0 (the --- "License"); you may not use this file except in compliance --- with the License. You may obtain a copy of the License at --- --- http://www.apache.org/licenses/LICENSE-2.0 --- --- Unless required by applicable law or agreed to in writing, software --- distributed under the License is distributed on an "AS IS" BASIS, --- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --- See the License for the specific language governing permissions and --- limitations under the License. --- --- Copyright (C) 2015 - 2017, TBOOX Open Source Group. --- --- @author ruki --- @file echo.lua --- - --- define task -task("echo") - - -- set category - set_category("plugin") - - -- on run - on_run(function () - - -- imports - import("core.base.option") - - -- init modes - local modes = "" - for _, mode in ipairs({"bright", "dim", "blink", "reverse"}) do - if option.get(mode) then - modes = modes .. " " .. mode - end - end - - -- echo info - cprint("${%s%s}%s", option.get("color"), modes, table.concat(option.get("contents") or {}, " ")) - end) - - -- set menu - set_menu { - -- usage - usage = "xmake echo [options]" - - -- description - , description = "Echo the given info!" - - -- options - , options = - { - {'b', "bright", "k", nil, "Enable bright." } - , {'d', "dim", "k", nil, "Enable dim." } - , {'-', "blink", "k", nil, "Enable blink." } - , {'r', "reverse", "k", nil, "Reverse color." } - , {} - , {'c', "color", "kv", "black", "Set the output color." - , " - red" - , " - blue" - , " - yellow" - , " - green" - , " - magenta" - , " - cyan" - , " - white" } - , {} - , {nil, "contents", "vs", nil, "The info contents." } - } - } |
