tags:

views:

17

answers:

1

I have a NAnt script like below:

<target name="Init" unless="${target::has-executed('Init')}">

What I want is to convert it into MSBuild script. What I can't do is to write MSBuild script to run a target only when it hasn't run like the above script.

Please help.

+2  A: 

Targets only run once in an MSBUild build process. So just have a CallTarget element, and if it's already run, it will be skipped.

Damien_The_Unbeliever