Frage

Ich Aufruf Dotfuscator Aufgabe über TFS Build-aka Team Build, genommen von - = Dotfuscator Aufgabe mit Team Build = - und den folgenden Fehler empfangen:

Build FAILED.


(AfterCompile target) -> 

error MSB4061: The "Dotfuscate" task could not be instantiated from the assembly "C:\Program Files\MSBuild\PreEmptive\Dotfuscator\4.0\PreEmptive.Dotfuscator.Tasks.dll". 

error MSB4061: System.InvalidOperationException: Showing a modal dialog box or form when the application is not running in UserInteractive mode is not a valid operation. Specify the ServiceNotification or DefaultDesktopOnly style to display a notification from a service application.

error MSB4061:    at System.Windows.Forms.Form.ShowDialog(IWin32Window owner)

error MSB4061:    at System.Windows.Forms.Form.ShowDialog()
error MSB4061:    at PreEmptive.Tasks.Dotfuscate.b()
error MSB4061:    at PreEmptive.Tasks.Dotfuscate.a()
error MSB4061:    at PreEmptive.Tasks.Dotfuscate..ctor()
error MSB4060: The "Dotfuscate" task has been declared or used incorrectly, or failed during construction. Check the spelling of the task name and the assembly name.

    0 Warning(s)
    2 Error(s)

Der Code relevant in Dotfuscator zu Dotfuscator ist wie folgt:

  <!---
  All Dotfuscation Stuff here...
  -->

  <PropertyGroup>
    <ConfigPath>$(SolutionRoot)\..\$(BuildDefinitionPath)\BuildType\dotfuscator.xml</ConfigPath>
    <!--<InputPath>$(OutDir)</InputPath>-->
    <InputPath>\\Dev-6\TempBuild\Output\</InputPath>
  </PropertyGroup>

  <ItemGroup>
    <InputAssembly Include="$(InputPath)\*.dll;$(InputPath)\*.exe" Exclude="$(InputPath)\*.vshost.exe"/>
  </ItemGroup>

  <Target Name="AfterCompile">

    <!--Perform obfuscation steps after assemblies are compiled.-->

    <Dotfuscate InputAssemblies="@(InputAssembly)" Properties="$(DotfuscatorProperties)" ConfigPath="$(ConfigPath)">
      <Output TaskParameter="MappingFile" ItemName="DotfuscatorMappingFile"/>
      <Output TaskParameter="ReportFiles" ItemName="DotfuscatorReportFiles"/>
      <Output TaskParameter="OutputAssemblies" ItemName="DotfuscatedAssemblies"/>
      <Output TaskParameter="SatelliteAssemblies" ItemName="DotfuscatedSatelliteAssemblies"/>
      <Output TaskParameter="DebugSymbols" ItemName="DotfuscatedDebugSymbols"/>
    </Dotfuscate>
  </Target>
  <!-- End of dotfuscation Stuf....-->

Ich bin mit der folgenden Dotfuscator Aufgabe:

<Import Project="$(MSBuildExtensionsPath)\PreEmptive\Dotfuscator\4.0\PreEmptive.Dotfuscator.Targets" />

Die Build-Maschine hat Dotfuscator Fachmann installiert. Seine voll funktionsfähig und funktioniert gut, wenn manuell verwendet.

Mit freundlicher Hilfe in diesem Problem.

Viele Grüße

War es hilfreich?

Lösung

Dies wird in der Regel durch den Build Service Sein Lauf unter einem anderen Konto verursacht. Dotfuscator erfordert die Annahme der EULA während es für jedes Benutzerkonto erste Ausführung ist es unter ausgeführt wird.

Sie können den Build-Server anmelden dem Konto, dass Ihr Build verwendet, führen Dotfuscator und die EULA akzeptieren. Sobald Sie getan haben, dass zukünftige Ausführungen unter diesem Konto nur gut funktionieren werden.

Wenn Sie sich nicht mit den Build Service Anmeldeinformationen an den Build-Server anmelden preemptive technischen Support können Sie mit einer alternativen Methode zu arbeiten, um diesen zur Verfügung stellen. Sie können Unterstützung bei support@preemptive.com kontaktieren oder ein Support-Ticket direkt unter http://preemptive.com/support.

scroll top