This task can be used to wrap any executable

Namespace: MSBuild.ExtensionPack.Framework
Assembly: MSBuild.ExtensionPack (in MSBuild.ExtensionPack.dll) Version: 3.5.0.0

Examples

Xml Copy imageCopy
<Project ToolsVersion="3.5" DefaultTargets="Default" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
    <PropertyGroup>
        <TPath>$(MSBuildProjectDirectory)\..\MSBuild.ExtensionPack.tasks</TPath>
        <TPath Condition="Exists('$(MSBuildProjectDirectory)\..\..\Common\MSBuild.ExtensionPack.tasks')">$(MSBuildProjectDirectory)\..\..\Common\MSBuild.ExtensionPack.tasks</TPath>
    </PropertyGroup>
    <Import Project="$(TPath)"/>
    <Target Name="Default">
        <ItemGroup>
            <Param Include="Source">
                <value>c:\b</value>
            </Param>
            <Param Include="Destination">
                <value>c:\bb 3</value>
            </Param>
            <Param Include="Files">
                <value>*.*</value>
            </Param>
            <Param Include="Options">
                <value>/Mir</value>
            </Param>
        </ItemGroup>
        <MSBuild.ExtensionPack.Framework.GenericTool Executable="robocopy.exe" Parameters="@(Param)" SuccessExitCodes="0;1" WarningExitCodes="2;4" ErrorExitCodes="8;16"/>
    </Target>
</Project>

Inheritance Hierarchy

System..::..Object
  Microsoft.Build.Utilities..::..Task
    Microsoft.Build.Utilities..::..ToolTask
      MSBuild.ExtensionPack.Framework..::..GenericTool

See Also