开发者

Using IvyDE with different workspaces on different branches

开发者 https://www.devze.com 2022-12-28 18:23 出处:网络
I am having problems using IvyDE when I have different workspaces for different branches.I have \"Resolve dependen开发者_如何学编程cies in workspace\" switched on.But everytime I change to a different

I am having problems using IvyDE when I have different workspaces for different branches. I have "Resolve dependen开发者_如何学编程cies in workspace" switched on. But everytime I change to a different workspace I have to remember to manually clean the caches out. This is because IvyDE always uses the default cache for resolving dependencies within a workspace, so when switching between workspaces the cache can be polluted by different versions.

It would seem that it is impossible to work with two different workspaces at the same time.

I cannot find a way to configure the location that IvyDE uses to cache the project dependencies. It does not appear to use the caches defined in the ivysettings.xml


I have now got a configuration that the latest version of IvyDE is using correctly.

In my ivysettings.xml I have included the line

<properties file="./revision.properties" />

This sets the property revision.version that is used by our headless build scripts.

I then set the following property

<property name="ivy.build.cache" value="${ivy.default.ivy.user.dir}/cache/${revision.version}" override="false" />

The default cache used by ivyDE is then set with the following configuration block

<caches defaultCacheDir="${ivy.build.cache}">
    <cache name="cache" basedir="${ivy.build.cache}" />
</caches>

Then any resolvers need to have this cache explicitly set as in:

<filesystem name="build" cache="cache" latest="latest-revision">

This doesn't help if you have multiple workspaces on the same branch. But it does mean that you can work on different branches at the same time without problems.

0

精彩评论

暂无评论...
验证码 换一张
取 消