加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

xcode – 如何使用Mogenerator?

发布时间:2020-12-15 01:58:12 所属栏目:百科 来源:网络整理
导读:我安装了 Mogenerator.现在我该怎么办?如何使用它? 我遇到的第一个问题是我不知道安装在哪里。在安装过程中,它只允许我选择硬盘来安装它,而不是目录。最自然的位置将是“应用程序”文件夹,但不存在。 接下来,readme(我在网上找到)说: Xmo’d works by
我安装了 Mogenerator.现在我该怎么办?如何使用它?

我遇到的第一个问题是我不知道安装在哪里。在安装过程中,它只允许我选择硬盘来安装它,而不是目录。最自然的位置将是“应用程序”文件夹,但不存在。

接下来,readme(我在网上找到)说:

Xmo’d works by noticing when your
*.xcdatamodel is saved. If the model file’s Xcode project item comment
contains xmod,an AppleScript is fired
that creates a folder based on your
model’s file name and populates it
with derived source code files from
your model. It then adds the new
folder to your project as a Group
Reference and adds all the source
files to your project.

上述声明有几个问题不清楚:

>“模型文件的Xcode项目项目注释”是什么引用?如何使其包含“xmod”?
>添加此评论并让mogenerator监控.xcdatamodel文件是使用mogenerator的唯一方法?有什么办法可以手动运行mogenerator,以便它重新生成生成的文件?

解决方法

mogenerator是一个脚本,我记得安装到您的开发人员目录中。但是,它可能会安装到您的?/ Library下的Xcode脚本目录中。

手动触发应用程序是什么意思?您可以通过“触摸”数据模型来触发构建。数据模型上的任何保存将触发构建

在Xcode中,如果您选择模型文件并点击?I,您将获得其元数据。点击评论选项卡并在其中添加xmod。 mogenerator查找该注释以知道它是否应该生成文件。

更新

您可以从命令行运行mogenerator,并让它监视您的文件。在终端中键入mogenerator –help以查看选项。

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读