Skip to content

Commit

Permalink
test: Zipping output to dist/zip
Browse files Browse the repository at this point in the history
  • Loading branch information
AlanRynne committed May 6, 2024
1 parent af7a134 commit 2cc5d97
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions DUI3-DX/Connectors/Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,27 @@
<Import Project="$([MSBuild]::GetPathOfFileAbove('Directory.Build.targets', '$(MSBuildThisFileDirectory)../'))"/>


<Target Name="Copy To Folder" AfterTargets="Build" Condition="'$(IsDesktopBuild)' == false">
<Target Name="Copy To Folder" AfterTargets="Build">

<Error Text="ConnectorSlug property is not set" Condition=" '$(ConnectorSlug)' == '' " />
<Error Text="ConnectorVersion property is not set" Condition=" '$(ConnectorVersion)' == '' " />

<PropertyGroup>
<OutputDirectory>$(RepositoryRoot)/dist/$(ConnectorSlug)/$(ConnectorVersion)</OutputDirectory>
<OutputZipDirectory>$(RepositoryRoot)/dist/zip</OutputZipDirectory>
<OutputZipFile>$(ConnectorSlug)-$(ConnectorVersion)-$(Version).zip</OutputZipFile>
</PropertyGroup>

<RemoveDir Directories="$(OutputDirectory)"/>
<MakeDir Directories="$(OutputDirectory)"/>
<MakeDir Directories="$(OutputZipDirectory)"/>

<ItemGroup>
<DllFiles Include="$(OutDir)**/*.*"/>
</ItemGroup>

<Copy SourceFiles="@(DllFiles)" DestinationFolder="$(OutputDirectory)/%(RecursiveDir)"/>


<ZipDirectory SourceDirectory="$(OutputDirectory)" DestinationFile="$(OutputZipDirectory)/$(OutputZipFile)"/>
</Target>
</Project>

0 comments on commit 2cc5d97

Please sign in to comment.