如何在Source Insight中保存配置模板?
我正在开展一个具有许多类似分支的项目。我想“一劳永逸”地配置 Source Insight——花时间分析应包含和排除文件/目录的大型项目,然后将其保存为配置,以便在启动新项目时在一个分支中,我几乎可以立即开始,只需进行一些小的调整。
有没有办法将项目配置信息保存到模板中,以便在将来的项目中使用?
I'm working on a project with many similar branches. I'd like to configure Source Insight "once and for all"--to spend the time analyzing the huge project for which files/directories should be included and excluded, and then saving that as a configuration, so that when starting a new project in a branch, I could get started almost immediately, with only minor tweaks.
Is there a way to save project configuration information into a template, to use on future projects?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Source Insight 有几种方法可以将文件和目录列表添加到项目中。最简单的方法是转到
Project >添加和删除项目文件...
,选择“从列表添加”,然后选择一个文件。该文件可以包含绝对文件路径或相对于Project > 中指定的项目源目录的路径。项目设置
。如果您愿意,还可以在 Source Insight 宏中使用AddFileListToProj(hprj, listfilename)
函数。从文档中:现在,您只需创建文件列表。您可以按照自己的意愿在外部进行此操作,也可以让 Source Insight 从之前的项目中创建一个。为此,只需打开要用作“模板”的项目并转到
Project >项目报告
。取消选中所有复选框并单击“确定”。现在删除报告顶部的标题行和底部的“总文件...”行。您应该留下项目中相对于项目源目录的所有文件的列表。保存此文件以供将来将文件添加到新项目时使用。Source Insight has a few ways to add a list of files and directories to a project. The easiest way is to go to
Project > Add And Remove Project Files...
, select "add from list", then select a file. This file can containt absolute file paths or paths relative to the Project Source Directory specified inProject > Project Settings
. You can also use theAddFileListToProj(hprj, listfilename)
function in a Source Insight macro if you'd like to do it that way. From the documentation:Now, you just need to create the list of files. You can either do it externally however you wish, or you can let Source Insight create one from a previous project. To do this, simiply open the project you want to use as your "template" and go to
Project > Project Report
. Uncheck all of the boxes and click "OK". Now delete the header lines from the top of the report and the "total files..." line from the bottom. You should be left with a list of all the files in the project relative to the project source directory. Save this file to use to add files to new projects in the future.