我遇到了和你一样的问题,并且找不到使用plugman合并资源的方法(也许这在过去几年里已经改变了)。
我所做的是,我制作了一个包含所有常见文件的插件,其基本内容如下:
<?xml version="1.0" encoding="UTF-8"?>
<resources>
</resources>
Run Code Online (Sandbox Code Playgroud)
然后在每个需要设置资源的插件中,我在plugin.xml中使用plugman语法:
<config-file target="res/values/ids.xml" parent="/resources">
<item type="id" name="id1"/>
<item type="id" name="id2"/>
<item type="id" name="id3"/>
</config-file>
<config-file target="res/values/strings.xml" parent="/resources">
<string name="message1">Hello</string>
<string name="message2">world!</string>
</config-file>
Run Code Online (Sandbox Code Playgroud)
最后,在您的插件中,您可以设置“基本资源”插件的需求。
该系统的限制是,如果您想发布您的插件,并且人们在其他插件覆盖与您相同的资源文件的同时使用它......
我当时发布了一个SO问题,但没有得到答案。我想我们可以直接向 jira 上的插件人员询问这个问题。
| 归档时间: |
|
| 查看次数: |
1089 次 |
| 最近记录: |