Skip to content

Commit

Permalink
Include build folder.
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinJump committed Jul 13, 2021
1 parent 0c4a9ac commit 8267574
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 1 deletion.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ App_Data/
Bin/
# Config/
Archive/
build/
[Mm]edia/*
![Mm]edia/[Ww]eb.config

Expand Down
11 changes: 11 additions & 0 deletions build/build.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
param($version, $suffix, $env='release', [switch]$push=$false)

$fullVersion = -join($version, '-', $suffix)
$outFolder = ".\$fullVersion"
$packageProj = "..\src\Our.Umbraco.LinkedPages\Our.Umbraco.LinkedPages.csproj"

dotnet pack $packageProj -c $env -o $outFolder /p:ContinuousIntegrationBuild=true,version=$fullVersion

if ($push) {
.\nuget.exe push "$outFolder\*.nupkg" -ApiKey AzureDevOps -src https://pkgs.dev.azure.com/jumoo/Public/_packaging/nightly/nuget/v3/index.json
}
27 changes: 27 additions & 0 deletions src/Our.Umbraco.LinkedPages/build/Our.Umbraco.LinkedPages.targets
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

<PropertyGroup>
<LinkedPagesPackageContentFilesPath>$(MSBuildThisFileDirectory)..\content\App_Plugins\LinkedPages\**\*.*</LinkedPagesPackageContentFilesPath>
</PropertyGroup>

<Target Name="CopyLinkedPagesPackageAssets" BeforeTargets="Build">
<ItemGroup>
<LinkedPagesPackageContentFiles Include="$(LinkedPagesPackageContentFilesPath)" />
</ItemGroup>
<Message Text="Copying LinkedPages Package files: $(LinkedPagesPackageContentFilesPath) - #@(LinkedPagesPackageContentFiles->Count()) files" Importance="high" />
<Copy
SourceFiles="@(LinkedPagesPackageContentFiles)"
DestinationFiles="@(LinkedPagesPackageContentFiles->'$(MSBuildProjectDirectory)\App_Plugins\LinkedPages\%(RecursiveDir)%(Filename)%(Extension)')"
SkipUnchangedFiles="true" />

</Target>

<Target Name="ClearLinkedPagesPackageAssets" BeforeTargets="Clean">
<ItemGroup>
<LinkedPagesPackageDir Include="$(MSBuildProjectDirectory)\App_Plugins\LinkedPages\" />
</ItemGroup>
<Message Text="Clear old LinkedPages Package data" Importance="high" />
<RemoveDir Directories="@(LinkedPagesPackageDir)" />
</Target>

</Project>

0 comments on commit 8267574

Please sign in to comment.