Dear ladies and sirs.
Observe the following piece of an msbuild script:
<ItemGroup>
<R Include="-Microsoft.Design#CA1000" />
<R Include="-Microsoft.Design#CA1002" />
</ItemGroup>
I want to convert it to
/ruleid:-Microsoft.Design#CA1000 /ruleid:-Microsoft.Design#CA1002
Now, the best I came up with is @(R -> '/ruleid:%(Identity)')
, but this only yields
/ruleid:-Microsoft.Design#CA1000;/ruleid:-Microsoft.Design#CA1002
Note the semi-colon separating the two rules, instead of a space. This is bad, it is not recognized by the fxcop - I need a space there.
Now, this is a simple example, so I could just declare something like this:
<PropertyGroup>
<R>/ruleid:-Microsoft.Design#CA1000 /ruleid:-Microsoft.Design#CA1002</R
</PropertyGroup>
But, I do not like this, because in reality I have many rules I wish to disable and listing all of them like this is something I wish to avoid.