質問

TFSビルドを介してDotfuscatorタスクを呼び出しています。 - =チームビルドを使用したdotfuscatorタスク= -次のエラーを受信します。

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)

dotfuscatorのdotfuscatorに関連するコードは次のとおりです。

  <!---
  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....-->

私は次のドットフューシータータスクを使用しています:

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

ビルドマシンには、Dotfuscator Professionalがインストールされています。完全に機能し、手動で使用すると正常に機能します。

この問題を手伝ってください。

よろしく

役に立ちましたか?

解決

これは通常、ビルドサービスが別のアカウントの下で実行されることによって引き起こされます。 Dotfuscatorは、実行中のユーザーアカウントごとに最初の実行中にEULAを受け入れる必要があります。

ビルドが使用しているアカウントを使用してビルドサーバーにログインし、dotfuscatorを実行してEULAを受け入れることができます。そのアカウントの下でその将来の実行を行ったら、正常に機能します。

ビルドサービスの資格情報を使用してビルドサーバーにログインできない場合、先制技術サポートは、これを回避するための代替方法を提供できます。 support@preemptive.comでサポートに連絡するか、サポートチケットを直接提出してください http://preemptive.com/support .

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top