Răsfoiți Sursa

improve intellsense

ruki 2 ani în urmă
părinte
comite
ee5a1e692c

+ 63 - 4
mirror/plugin/more_plugins.html

@@ -116,9 +116,68 @@
 ...
 }
 </code></pre><p>Other xmake options can also be setted in settings.json. After modification, the configuration can be refreshed through the >XMake: Configure command.</p>
-<h3 id="improvethedevelopmentexperiencewithlsp">Improve the development experience with LSP</h3>
-<p>For a better C++ intellisense experience, xmake provides support for <a href="https://microsoft.github.io/language-server-protocol/">Language Server Protocol</a> (LSP for short). In vscode, you can use the >XMake: UpdateIntellisense command to generate .vscode/compile_commands.json (usually when modifying xmake.lua, this file will be generated automatically). At the same time, we can choose to install a intellisense plug-in that supports LSP, such as <a href="https://clangd.llvm.org/">clangd</a> published by LLVM, which is stable and efficient, and support different tool-chain through the LSP standard.</p>
-<p>When using clangd, there may be conflicts with the C/C++ plug-in, you can add settings in .vscode/settings.json: </p>
+<h3 id="configureintellsence">Configure Intellsence</h3>
+<p>For a better C++ syntax prompt experience, xmake provides support for <a href="https://microsoft.github.io/language-server-protocol/">Language Server Protocol</a> (LSP for short).</p>
+<p>In vscode, we can provide intellsence support by using vscode-cpptools or clangd.</p>
+<p>In addition, in order to support intellsence, xmake provides compile_commands.json generation support.</p>
+<h4 id="generatecompile_commands">generate compile_commands</h4>
+<h5 id="automatictriggergeneration">Automatic trigger generation</h5>
+<p>Usually after modifying xmake.lua and clicking Save, the xmake-vscode plugin will trigger the automatic generation of compile_commands.json, which is stored in the .vscode directory by default.</p>
+<p>This is also the recommended way. Usually after installing the xmake-vscode plug-in and opening the project with xmake.lua, you only need to edit xmake.lua to save and trigger without any other additional operations.</p>
+<h5 id="manuallytriggergeneration">Manually trigger generation</h5>
+<p>Of course, if we don’t see the file being generated, we can also use the <code>>XMake: UpdateIntellisense</code> command to manually trigger the generation of .vscode/compile_commands.json in vscode.</p>
+<h5 id="configurexmakeluatogenerateautomatically">Configure xmake.lua to generate automatically</h5>
+<p>Alternatively, we can also use this rule to automatically update and generate compile_commandss.json</p>
+<pre><code class="lang-lua">add_rules("plugin.compile_commands.autoupdate", {outputdir = ".vscode"})
+target("test")
+     set_kind("binary")
+     add_files("src/*.c")
+</code></pre>
+<p>This will automatically update this file after each build.</p>
+<h5 id="manualexecutioncommandgeneration">Manual execution command generation</h5>
+<p>If the above methods are invalid, we can also execute the command to generate.</p>
+<pre><code class="lang-console">$ xmake project -k compile_commands .vscode
+</code></pre>
+<h4 id="vscodecpptools">vscode-cpptools</h4>
+<p>If we use the vscode-cpptools plug-in to provide intellsence support, we need to go to the vscode plug-in market first, search for C++, the default first plug-in is to install it.</p>
+<p>When installed, this plugin provides intellsence and debugging support.</p>
+<p>Then, we need to configure the c_cpp_properties.json file and associate it with the <code>.vscode/compile_commands.json</code> we generated.</p>
+<pre><code>{
+   "env": {
+     "myDefaultIncludePath": ["${workspaceFolder}", "${workspaceFolder}/include"],
+     "myCompilerPath": "/usr/local/bin/gcc-7"
+   },
+   "configurations": [
+     {
+       "name": "Mac",
+       "intelliSenseMode": "clang-x64",
+       "includePath": ["${myDefaultIncludePath}", "/another/path"],
+       "macFrameworkPath": ["/System/Library/Frameworks"],
+       "defines": ["FOO", "BAR=100"],
+       "forcedInclude": ["${workspaceFolder}/include/config.h"],
+       "compilerPath": "/usr/bin/clang",
+       "cStandard": "c11",
+       "cppStandard": "c++17",
+       "compileCommands": "/path/to/compile_commands.json",
+       "browse": {
+         "path": ["${workspaceFolder}"],
+         "limitSymbolsToIncludedHeaders": true,
+         "databaseFilename": ""
+       }
+     }
+   ],
+   "version": 4
+}
+</code></pre><p>That is the <code>"compileCommands": "/path/to/compile_commands.json"</code> configuration item above.</p>
+<p>For how to open this configuration file, and more configuration instructions, see:</p>
+<ul>
+<li><a href="https://code.visualstudio.com/docs/cpp/configure-intellisense-crosscompilation">https://code.visualstudio.com/docs/cpp/configure-intellisense-crosscompilation</a></li>
+<li><a href="https://code.visualstudio.com/docs/cpp/c-cpp-properties-schema-reference">https://code.visualstudio.com/docs/cpp/c-cpp-properties-schema-reference</a></li>
+</ul>
+<p>Of course, in theory, the xmake-vscode plugin can automatically associate and set this file, but considering that users do not necessarily use cpptools, they may also use clangd.</p>
+<p>Therefore, the default automatic configuration is not very good, and the author has no time and energy to improve it.</p>
+<h4 id="clangd">clangd</h4>
+<p>When using clangd, there may be conflicts with the C/C++ plug-in, you can add settings in .vscode/settings.json:</p>
 <pre><code>{
   "C_Cpp.codeAnalysis.runAutomatically": false,
   "C_Cpp.intelliSenseEngine": "Disabled",
@@ -129,7 +188,7 @@
   "C_Cpp.errorSquiggles": "Disabled",
 ...
 }
-</code></pre><p>Also, since the compile_commands.json generated by XMake is in the .vscode directory, you need to set the clangd parameter to look for it in the correct location: </p>
+</code></pre><p>Also, since the compile_commands.json generated by XMake is in the .vscode directory, you need to set the clangd parameter to look for it in the correct location:</p>
 <pre><code>{
   "clangd.arguments": [
     "--compile-commands-dir=.vscode",

+ 66 - 5
mirror/zh-cn/plugin/more_plugins.html

@@ -116,9 +116,69 @@
 ...
 }
 </code></pre><p>其他xmake的选项也同样可以在settings.json中完成设置。修改后可通过 >XMake: Configure 命令刷新配置。</p>
-<h3 id="lsp">使用LSP提高开发体验</h3>
-<p>为了更好的C++语法提示体验,xmake提供了对<a href="https://microsoft.github.io/language-server-protocol/">Language Server Protocol</a>(简称LSP)的支持,在vscode中,可以使用 <code>>XMake: UpdateIntellisense</code> 命令生成.vscode/compile_commands.json(通常在修改xmake.lua时该文件会自动生成)。与此同时,我们可以选择安装支持LSP的语法提示插件,如LLVM推出的<a href="https://clangd.llvm.org/">clangd</a>,其功能稳定且提示流畅,并通过LSP标准完成对不同编译工具链的支持。</p>
-<p>使用clangd时,可能与上述的C/C++插件的提示功能有冲突,可以在.vscode/settings.json中添加设置将C/C++的语法提示功能关闭:</p>
+<h3 id="intellsence">配置 Intellsence</h3>
+<p>为了更好的 C++ 语法提示体验,xmake提供了对<a href="https://microsoft.github.io/language-server-protocol/">Language Server Protocol</a>(简称LSP)的支持。</p>
+<p>在 vscode 中,我们可以通过使用 vscode-cpptools 或者 clangd 来提供 intellsence 支持。</p>
+<p>另外,为了支持 intellsence,xmake 提供了 compile_commands.json 的生成支持。</p>
+<h4 id="compile_commands">生成 compile_commands</h4>
+<h5 id="">自动触发生成</h5>
+<p>通常在修改 xmake.lua 后点击保存,xmake-vscode 插件就会触发自动生成 compile_commands.json,默认存储在 .vscode 目录下。</p>
+<p>这也是推荐方式,通常装完 xmake-vscode 插件,打开带有 xmake.lua 的工程后,只需要编辑 xmake.lua 保存即可触发,不需要任何其他额外操作。</p>
+<h5 id="">手动触发生成</h5>
+<p>当然,如果没看到文件被生成,我们也可以在 vscode 中,可以使用 <code>>XMake: UpdateIntellisense</code> 命令手动触发生成 .vscode/compile_commands.json。</p>
+<h5 id="xmakelua">配置 xmake.lua 自动生成</h5>
+<p>或者,我们也可以使用这个规则来自动更新生成 compile_commandss.json</p>
+<pre><code class="lang-lua">add_rules("plugin.compile_commands.autoupdate", {outputdir = ".vscode"})
+target("test")
+    set_kind("binary")
+    add_files("src/*.c")
+</code></pre>
+<p>这会使得在每次 build 后,自动更新此文件。</p>
+<h5 id="">手动执行命令生成</h5>
+<p>如果上述方式都无效,我们也可以执行命令来生成。</p>
+<pre><code class="lang-console">$ xmake project -k compile_commands .vscode
+</code></pre>
+<h4 id="vscodecpptools">vscode-cpptools</h4>
+<p>如果我们使用 vscode-cpptools 插件来提供 intellsence 支持,需要先去 vscode 插件市场,搜下 C++,默认第一个插件就是,安装下。</p>
+<p>装完后,这个插件提供了 intellsence 和 调试支持。</p>
+<p>然后,我们需要配置下 c_cpp_properties.json 文件,关联上我们生成的 <code>.vscode/compile_commands.json</code>。</p>
+<pre><code>{
+  "env": {
+    "myDefaultIncludePath": ["${workspaceFolder}", "${workspaceFolder}/include"],
+    "myCompilerPath": "/usr/local/bin/gcc-7"
+  },
+  "configurations": [
+    {
+      "name": "Mac",
+      "intelliSenseMode": "clang-x64",
+      "includePath": ["${myDefaultIncludePath}", "/another/path"],
+      "macFrameworkPath": ["/System/Library/Frameworks"],
+      "defines": ["FOO", "BAR=100"],
+      "forcedInclude": ["${workspaceFolder}/include/config.h"],
+      "compilerPath": "/usr/bin/clang",
+      "cStandard": "c11",
+      "cppStandard": "c++17",
+      "compileCommands": "/path/to/compile_commands.json",
+      "browse": {
+        "path": ["${workspaceFolder}"],
+        "limitSymbolsToIncludedHeaders": true,
+        "databaseFilename": ""
+      }
+    }
+  ],
+  "version": 4
+}
+</code></pre><p>也就是上面的 <code>"compileCommands": "/path/to/compile_commands.json"</code> 配置项。</p>
+<p>关于如果打开这个配置文件,以及更多的配置说明,见:</p>
+<ul>
+<li><a href="https://code.visualstudio.com/docs/cpp/configure-intellisense-crosscompilation">https://code.visualstudio.com/docs/cpp/configure-intellisense-crosscompilation</a></li>
+<li><a href="https://code.visualstudio.com/docs/cpp/c-cpp-properties-schema-reference">https://code.visualstudio.com/docs/cpp/c-cpp-properties-schema-reference</a></li>
+</ul>
+<p>当然,理论上可以做到 xmake-vscode 插件自动关联设置这个文件,但是考虑到用户不一定使用 cpptools,有可能还会使用 clangd。</p>
+<p>因此,默认自动配置并不是很好,而且作者暂时也没时间精力去改进它。</p>
+<h4 id="clangd">clangd</h4>
+<p>与此同时,我们可以选择安装支持 LSP 的语法提示插件,如 LLVM 推出的<a href="https://clangd.llvm.org/">clangd</a>,其功能稳定且提示流畅,<br>并通过 LSP 标准完成对不同编译工具链的支持。</p>
+<p>使用 clangd 时,可能与上述的C/C++插件的提示功能有冲突,可以在 .vscode/settings.json 中添加设置将C/C++的语法提示功能关闭:</p>
 <pre><code>{
   "C_Cpp.codeAnalysis.runAutomatically": false,
   "C_Cpp.intelliSenseEngine": "Disabled",
@@ -129,7 +189,7 @@
   "C_Cpp.errorSquiggles": "Disabled",
 ...
 }
-</code></pre><p>同时由于XMake生成的compile_commands.json在.vscode目录,还需要设置clangd传参使其在正确位置寻找:</p>
+</code></pre><p>同时由于 XMake 生成的 compile_commands.json  .vscode 目录,还需要设置 clangd 传参使其在正确位置寻找:</p>
 <pre><code>{
   "clangd.arguments": [
     "--compile-commands-dir=.vscode",
@@ -137,7 +197,8 @@
   ]
 ...
 }
-</code></pre><h2 id="sublime">Sublime 插件</h2>
+</code></pre><p>如果配置后,还是没生效,可以尝试重启 vscode 和 clangd 进程,再验证下。</p>
+<h2 id="sublime">Sublime 插件</h2>
 <ul>
 <li><a href="https://github.com/xmake-io/xmake-sublime">xmake-sublime</a></li>
 </ul>

+ 91 - 4
plugin/more_plugins.md

@@ -37,11 +37,98 @@ If these options are not enough, you can create .vscode/settings.json and write
 
 Other xmake options can also be setted in settings.json. After modification, the configuration can be refreshed through the >XMake: Configure command.
 
-### Improve the development experience with LSP
+### Configure Intellsence
 
-For a better C++ intellisense experience, xmake provides support for [Language Server Protocol](https://microsoft.github.io/language-server-protocol/) (LSP for short). In vscode, you can use the >XMake: UpdateIntellisense command to generate .vscode/compile_commands.json (usually when modifying xmake.lua, this file will be generated automatically). At the same time, we can choose to install a intellisense plug-in that supports LSP, such as [clangd](https://clangd.llvm.org/) published by LLVM, which is stable and efficient, and support different tool-chain through the LSP standard.
+For a better C++ syntax prompt experience, xmake provides support for [Language Server Protocol](https://microsoft.github.io/language-server-protocol/) (LSP for short).
 
-When using clangd, there may be conflicts with the C/C++ plug-in, you can add settings in .vscode/settings.json: 
+In vscode, we can provide intellsence support by using vscode-cpptools or clangd.
+
+In addition, in order to support intellsence, xmake provides compile_commands.json generation support.
+
+#### generate compile_commands
+
+##### Automatic trigger generation
+
+Usually after modifying xmake.lua and clicking Save, the xmake-vscode plugin will trigger the automatic generation of compile_commands.json, which is stored in the .vscode directory by default.
+
+This is also the recommended way. Usually after installing the xmake-vscode plug-in and opening the project with xmake.lua, you only need to edit xmake.lua to save and trigger without any other additional operations.
+
+##### Manually trigger generation
+
+Of course, if we don’t see the file being generated, we can also use the `>XMake: UpdateIntellisense` command to manually trigger the generation of .vscode/compile_commands.json in vscode.
+
+##### Configure xmake.lua to generate automatically
+
+Alternatively, we can also use this rule to automatically update and generate compile_commandss.json
+
+```lua
+add_rules("plugin.compile_commands.autoupdate", {outputdir = ".vscode"})
+target("test")
+     set_kind("binary")
+     add_files("src/*.c")
+```
+
+This will automatically update this file after each build.
+
+##### Manual execution command generation
+
+If the above methods are invalid, we can also execute the command to generate.
+
+```console
+$ xmake project -k compile_commands .vscode
+```
+
+#### vscode-cpptools
+
+If we use the vscode-cpptools plug-in to provide intellsence support, we need to go to the vscode plug-in market first, search for C++, the default first plug-in is to install it.
+
+When installed, this plugin provides intellsence and debugging support.
+
+Then, we need to configure the c_cpp_properties.json file and associate it with the `.vscode/compile_commands.json` we generated.
+
+```
+{
+   "env": {
+     "myDefaultIncludePath": ["${workspaceFolder}", "${workspaceFolder}/include"],
+     "myCompilerPath": "/usr/local/bin/gcc-7"
+   },
+   "configurations": [
+     {
+       "name": "Mac",
+       "intelliSenseMode": "clang-x64",
+       "includePath": ["${myDefaultIncludePath}", "/another/path"],
+       "macFrameworkPath": ["/System/Library/Frameworks"],
+       "defines": ["FOO", "BAR=100"],
+       "forcedInclude": ["${workspaceFolder}/include/config.h"],
+       "compilerPath": "/usr/bin/clang",
+       "cStandard": "c11",
+       "cppStandard": "c++17",
+       "compileCommands": "/path/to/compile_commands.json",
+       "browse": {
+         "path": ["${workspaceFolder}"],
+         "limitSymbolsToIncludedHeaders": true,
+         "databaseFilename": ""
+       }
+     }
+   ],
+   "version": 4
+}
+```
+
+That is the `"compileCommands": "/path/to/compile_commands.json"` configuration item above.
+
+For how to open this configuration file, and more configuration instructions, see:
+
+- https://code.visualstudio.com/docs/cpp/configure-intellisense-crosscompilation
+- https://code.visualstudio.com/docs/cpp/c-cpp-properties-schema-reference
+
+Of course, in theory, the xmake-vscode plugin can automatically associate and set this file, but considering that users do not necessarily use cpptools, they may also use clangd.
+
+Therefore, the default automatic configuration is not very good, and the author has no time and energy to improve it.
+
+#### clangd
+
+When using clangd, there may be conflicts with the C/C++ plug-in, you can add settings in .vscode/settings.json:
 
 ```
 {
@@ -56,7 +143,7 @@ When using clangd, there may be conflicts with the C/C++ plug-in, you can add se
 }
 ```
 
-Also, since the compile_commands.json generated by XMake is in the .vscode directory, you need to set the clangd parameter to look for it in the correct location: 
+Also, since the compile_commands.json generated by XMake is in the .vscode directory, you need to set the clangd parameter to look for it in the correct location:
 
 ```
 {

+ 100 - 100
sitemap.xml

@@ -12,502 +12,502 @@
 
 <url>
   <loc>https://xmake.io/mirror/guide/project_examples.html</loc>
-  <lastmod>2023-02-20T15:29:31+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:41+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/guide/quickstart.html</loc>
-  <lastmod>2023-02-20T15:29:31+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:41+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/guide/faq.html</loc>
-  <lastmod>2023-02-20T15:29:32+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:42+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/guide/configuration.html</loc>
-  <lastmod>2023-02-20T15:29:32+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:42+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/guide/syntax_description.html</loc>
-  <lastmod>2023-02-20T15:29:32+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:42+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/guide/installation.html</loc>
-  <lastmod>2023-02-20T15:29:32+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:42+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/features/remote_build.html</loc>
-  <lastmod>2023-02-20T15:29:32+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:42+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/features/unity_build.html</loc>
-  <lastmod>2023-02-20T15:29:33+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:43+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/features/distcc_build.html</loc>
-  <lastmod>2023-02-20T15:29:33+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:43+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/features/trybuild.html</loc>
-  <lastmod>2023-02-20T15:29:33+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:43+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/features/autogen.html</loc>
-  <lastmod>2023-02-20T15:29:33+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:43+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/features/build_cache.html</loc>
-  <lastmod>2023-02-20T15:29:33+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:43+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/plugin/plugin_development.html</loc>
-  <lastmod>2023-02-20T15:29:34+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:44+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/plugin/more_plugins.html</loc>
-  <lastmod>2023-02-20T15:29:34+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:44+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/plugin/builtin_plugins.html</loc>
-  <lastmod>2023-02-20T15:29:34+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:44+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/about/awesome.html</loc>
-  <lastmod>2023-02-20T15:29:34+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:44+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/about/technical_support.html</loc>
-  <lastmod>2023-02-20T15:29:34+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:45+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/about/changelog.html</loc>
-  <lastmod>2023-02-20T15:29:35+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:45+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/about/contact.html</loc>
-  <lastmod>2023-02-20T15:29:35+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:45+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/about/introduction.html</loc>
-  <lastmod>2023-02-20T15:29:35+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:45+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/about/who_is_using_xmake.html</loc>
-  <lastmod>2023-02-20T15:29:35+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:45+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/about/sponsor.html</loc>
-  <lastmod>2023-02-20T15:29:36+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:46+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/index.html</loc>
-  <lastmod>2023-02-20T15:29:36+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:46+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/guide/project_examples.html</loc>
-  <lastmod>2023-02-20T15:29:36+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:46+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/guide/quickstart.html</loc>
-  <lastmod>2023-02-20T15:29:36+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:46+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/guide/faq.html</loc>
-  <lastmod>2023-02-20T15:29:36+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:46+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/guide/configuration.html</loc>
-  <lastmod>2023-02-20T15:29:37+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:47+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/guide/syntax_description.html</loc>
-  <lastmod>2023-02-20T15:29:37+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:47+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/guide/installation.html</loc>
-  <lastmod>2023-02-20T15:29:37+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:47+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/features/remote_build.html</loc>
-  <lastmod>2023-02-20T15:29:37+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:47+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/features/unity_build.html</loc>
-  <lastmod>2023-02-20T15:29:37+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:47+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/features/distcc_build.html</loc>
-  <lastmod>2023-02-20T15:29:38+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:48+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/features/trybuild.html</loc>
-  <lastmod>2023-02-20T15:29:38+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:48+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/features/autogen.html</loc>
-  <lastmod>2023-02-20T15:29:38+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:48+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/features/build_cache.html</loc>
-  <lastmod>2023-02-20T15:29:38+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:48+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/plugin/plugin_development.html</loc>
-  <lastmod>2023-02-20T15:29:38+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:48+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/plugin/more_plugins.html</loc>
-  <lastmod>2023-02-20T15:29:39+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:49+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/plugin/builtin_plugins.html</loc>
-  <lastmod>2023-02-20T15:29:39+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:49+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/awesome.html</loc>
-  <lastmod>2023-02-20T15:29:39+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:49+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/technical_support.html</loc>
-  <lastmod>2023-02-20T15:29:39+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:49+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/changelog.html</loc>
-  <lastmod>2023-02-20T15:29:40+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:50+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/contact.html</loc>
-  <lastmod>2023-02-20T15:29:40+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:50+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/peripheral_items.html</loc>
-  <lastmod>2023-02-20T15:29:40+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:50+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/introduction.html</loc>
-  <lastmod>2023-02-20T15:29:40+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:50+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/who_is_using_xmake.html</loc>
-  <lastmod>2023-02-20T15:29:40+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:50+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/sponsor.html</loc>
-  <lastmod>2023-02-20T15:29:41+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:51+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/about/course.html</loc>
-  <lastmod>2023-02-20T15:29:41+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:51+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/index.html</loc>
-  <lastmod>2023-02-20T15:29:41+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:51+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/getting_started.html</loc>
-  <lastmod>2023-02-20T15:29:41+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:51+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/specification.html</loc>
-  <lastmod>2023-02-20T15:29:41+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:51+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/builtin_variables.html</loc>
-  <lastmod>2023-02-20T15:29:41+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:52+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/conditions.html</loc>
-  <lastmod>2023-02-20T15:29:42+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:52+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/custom_rule.html</loc>
-  <lastmod>2023-02-20T15:29:42+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:52+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/target_instance.html</loc>
-  <lastmod>2023-02-20T15:29:42+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:52+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/project_target.html</loc>
-  <lastmod>2023-02-20T15:29:42+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:53+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/builtin_modules.html</loc>
-  <lastmod>2023-02-20T15:29:42+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:53+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/custom_toolchain.html</loc>
-  <lastmod>2023-02-20T15:29:43+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:53+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/plugin_task.html</loc>
-  <lastmod>2023-02-20T15:29:43+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:53+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/package_dependencies.html</loc>
-  <lastmod>2023-02-20T15:29:43+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:53+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/configuration_option.html</loc>
-  <lastmod>2023-02-20T15:29:43+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:54+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/extension_modules.html</loc>
-  <lastmod>2023-02-20T15:29:43+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:54+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/helper_interfaces.html</loc>
-  <lastmod>2023-02-20T15:29:44+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:54+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/global_interfaces.html</loc>
-  <lastmod>2023-02-20T15:29:44+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:54+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/package_instance.html</loc>
-  <lastmod>2023-02-20T15:29:44+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:54+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/manual/option_instance.html</loc>
-  <lastmod>2023-02-20T15:29:44+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:55+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/theme/builtin_themes.html</loc>
-  <lastmod>2023-02-20T15:29:44+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:55+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/theme/switch_theme.html</loc>
-  <lastmod>2023-02-20T15:29:45+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:55+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/package/local_3rd_source_library.html</loc>
-  <lastmod>2023-02-20T15:29:45+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:55+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/package/local_package_old.html</loc>
-  <lastmod>2023-02-20T15:29:45+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:56+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/package/local_package.html</loc>
-  <lastmod>2023-02-20T15:29:45+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:56+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/package/system_package.html</loc>
-  <lastmod>2023-02-20T15:29:45+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:56+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/package/remote_package.html</loc>
-  <lastmod>2023-02-20T15:29:46+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:56+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/toolchain/remote_toolchain.html</loc>
-  <lastmod>2023-02-20T15:29:46+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:56+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/zh-cn/toolchain/builtin_toolchains.html</loc>
-  <lastmod>2023-02-20T15:29:46+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:57+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/getting_started.html</loc>
-  <lastmod>2023-02-20T15:29:46+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:57+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/specification.html</loc>
-  <lastmod>2023-02-20T15:29:46+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:57+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/builtin_variables.html</loc>
-  <lastmod>2023-02-20T15:29:46+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:57+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/conditions.html</loc>
-  <lastmod>2023-02-20T15:29:47+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:58+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/custom_rule.html</loc>
-  <lastmod>2023-02-20T15:29:47+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:58+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/target_instance.html</loc>
-  <lastmod>2023-02-20T15:29:47+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:58+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/project_target.html</loc>
-  <lastmod>2023-02-20T15:29:47+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:58+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/builtin_modules.html</loc>
-  <lastmod>2023-02-20T15:29:47+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:59+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/custom_toolchain.html</loc>
-  <lastmod>2023-02-20T15:29:48+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:59+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/plugin_task.html</loc>
-  <lastmod>2023-02-20T15:29:48+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:59+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/package_dependencies.html</loc>
-  <lastmod>2023-02-20T15:29:48+08:00</lastmod>
+  <lastmod>2023-02-21T10:29:59+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/configuration_option.html</loc>
-  <lastmod>2023-02-20T15:29:48+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:00+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/extension_modules.html</loc>
-  <lastmod>2023-02-20T15:29:48+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:00+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/helper_interfaces.html</loc>
-  <lastmod>2023-02-20T15:29:49+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:00+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/global_interfaces.html</loc>
-  <lastmod>2023-02-20T15:29:49+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:00+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/package_instance.html</loc>
-  <lastmod>2023-02-20T15:29:49+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:01+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/manual/option_instance.html</loc>
-  <lastmod>2023-02-20T15:29:49+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:01+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/theme/builtin_themes.html</loc>
-  <lastmod>2023-02-20T15:29:49+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:01+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/theme/switch_theme.html</loc>
-  <lastmod>2023-02-20T15:29:50+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:01+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/package/local_3rd_source_library.html</loc>
-  <lastmod>2023-02-20T15:29:50+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:02+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/package/local_package_old.html</loc>
-  <lastmod>2023-02-20T15:29:50+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:02+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/package/local_package.html</loc>
-  <lastmod>2023-02-20T15:29:50+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:02+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/package/system_package.html</loc>
-  <lastmod>2023-02-20T15:29:50+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:02+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/package/remote_package.html</loc>
-  <lastmod>2023-02-20T15:29:50+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:02+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/toolchain/remote_toolchain.html</loc>
-  <lastmod>2023-02-20T15:29:51+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:03+08:00</lastmod>
 </url>
 
 <url>
   <loc>https://xmake.io/mirror/toolchain/builtin_toolchains.html</loc>
-  <lastmod>2023-02-20T15:29:51+08:00</lastmod>
+  <lastmod>2023-02-21T10:30:03+08:00</lastmod>
 </url>
 
 </urlset>

+ 96 - 4
zh-cn/plugin/more_plugins.md

@@ -37,11 +37,101 @@
 
 其他xmake的选项也同样可以在settings.json中完成设置。修改后可通过 >XMake: Configure 命令刷新配置。
 
-### 使用LSP提高开发体验
+### 配置 Intellsence
 
-为了更好的C++语法提示体验,xmake提供了对[Language Server Protocol](https://microsoft.github.io/language-server-protocol/)(简称LSP)的支持,在vscode中,可以使用 `>XMake: UpdateIntellisense` 命令生成.vscode/compile_commands.json(通常在修改xmake.lua时该文件会自动生成)。与此同时,我们可以选择安装支持LSP的语法提示插件,如LLVM推出的[clangd](https://clangd.llvm.org/),其功能稳定且提示流畅,并通过LSP标准完成对不同编译工具链的支持。
+为了更好的 C++ 语法提示体验,xmake提供了对[Language Server Protocol](https://microsoft.github.io/language-server-protocol/)(简称LSP)的支持。
 
-使用clangd时,可能与上述的C/C++插件的提示功能有冲突,可以在.vscode/settings.json中添加设置将C/C++的语法提示功能关闭:
+在 vscode 中,我们可以通过使用 vscode-cpptools 或者 clangd 来提供 intellsence 支持。
+
+另外,为了支持 intellsence,xmake 提供了 compile_commands.json 的生成支持。
+
+#### 生成 compile_commands
+
+##### 自动触发生成
+
+通常在修改 xmake.lua 后点击保存,xmake-vscode 插件就会触发自动生成 compile_commands.json,默认存储在 .vscode 目录下。
+
+这也是推荐方式,通常装完 xmake-vscode 插件,打开带有 xmake.lua 的工程后,只需要编辑 xmake.lua 保存即可触发,不需要任何其他额外操作。
+
+##### 手动触发生成
+
+当然,如果没看到文件被生成,我们也可以在 vscode 中,可以使用 `>XMake: UpdateIntellisense` 命令手动触发生成 .vscode/compile_commands.json。
+
+##### 配置 xmake.lua 自动生成
+
+或者,我们也可以使用这个规则来自动更新生成 compile_commandss.json
+
+```lua
+add_rules("plugin.compile_commands.autoupdate", {outputdir = ".vscode"})
+target("test")
+    set_kind("binary")
+    add_files("src/*.c")
+```
+
+这会使得在每次 build 后,自动更新此文件。
+
+##### 手动执行命令生成
+
+如果上述方式都无效,我们也可以执行命令来生成。
+
+```console
+$ xmake project -k compile_commands .vscode
+```
+
+#### vscode-cpptools
+
+如果我们使用 vscode-cpptools 插件来提供 intellsence 支持,需要先去 vscode 插件市场,搜下 C++,默认第一个插件就是,安装下。
+
+装完后,这个插件提供了 intellsence 和 调试支持。
+
+然后,我们需要配置下 c_cpp_properties.json 文件,关联上我们生成的 `.vscode/compile_commands.json`。
+
+```
+{
+  "env": {
+    "myDefaultIncludePath": ["${workspaceFolder}", "${workspaceFolder}/include"],
+    "myCompilerPath": "/usr/local/bin/gcc-7"
+  },
+  "configurations": [
+    {
+      "name": "Mac",
+      "intelliSenseMode": "clang-x64",
+      "includePath": ["${myDefaultIncludePath}", "/another/path"],
+      "macFrameworkPath": ["/System/Library/Frameworks"],
+      "defines": ["FOO", "BAR=100"],
+      "forcedInclude": ["${workspaceFolder}/include/config.h"],
+      "compilerPath": "/usr/bin/clang",
+      "cStandard": "c11",
+      "cppStandard": "c++17",
+      "compileCommands": "/path/to/compile_commands.json",
+      "browse": {
+        "path": ["${workspaceFolder}"],
+        "limitSymbolsToIncludedHeaders": true,
+        "databaseFilename": ""
+      }
+    }
+  ],
+  "version": 4
+}
+```
+
+也就是上面的 `"compileCommands": "/path/to/compile_commands.json"` 配置项。
+
+关于如果打开这个配置文件,以及更多的配置说明,见:
+
+- https://code.visualstudio.com/docs/cpp/configure-intellisense-crosscompilation
+- https://code.visualstudio.com/docs/cpp/c-cpp-properties-schema-reference
+
+当然,理论上可以做到 xmake-vscode 插件自动关联设置这个文件,但是考虑到用户不一定使用 cpptools,有可能还会使用 clangd。
+
+因此,默认自动配置并不是很好,而且作者暂时也没时间精力去改进它。
+
+#### clangd
+
+与此同时,我们可以选择安装支持 LSP 的语法提示插件,如 LLVM 推出的[clangd](https://clangd.llvm.org/),其功能稳定且提示流畅,
+并通过 LSP 标准完成对不同编译工具链的支持。
+
+使用 clangd 时,可能与上述的C/C++插件的提示功能有冲突,可以在 .vscode/settings.json 中添加设置将C/C++的语法提示功能关闭:
 
 ```
 {
@@ -56,7 +146,7 @@
 }
 ```
 
-同时由于XMake生成的compile_commands.json在.vscode目录,还需要设置clangd传参使其在正确位置寻找:
+同时由于 XMake 生成的 compile_commands.json  .vscode 目录,还需要设置 clangd 传参使其在正确位置寻找:
 
 ```
 {
@@ -68,6 +158,8 @@
 }
 ```
 
+如果配置后,还是没生效,可以尝试重启 vscode 和 clangd 进程,再验证下。
+
 ## Sublime 插件
 
 * [xmake-sublime](https://github.com/xmake-io/xmake-sublime)