Skip to content

Commit efd431c

Browse files
author
Friedrich Weinmann
committed
dirty workaround for the build sequence
1 parent 7a764e7 commit efd431c

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

templates/build.ps1

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,6 @@ $templateJoinList = $templateJoinList | Where-Object {
4949
}
5050

5151
$listToProcess = $templateJoinList
52-
#TODO: Debug, delete it
53-
$global:transfers = @{ }
5452
while ($listToProcess)
5553
{
5654
$processingThisTime = $listToProcess | Where-Object Name -NotIn $listToProcess.Parent
@@ -63,11 +61,15 @@ while ($listToProcess)
6361
{
6462
Get-ChildItem -Path "$($staging.FullName)\$($item.Name)\*" | Where-Object Name -NotMatch '\.PSMDDependency|PSMDInvoke\.ps1|PSMDTemplate\.ps1' | ForEach-Object {
6563
Write-PSFMessage -Level Verbose -Message "Copying from $($item.Name): $($_.FullName) to $($item.Parent)\$($item.Path)"
66-
67-
#TODO: Debug, delete it
68-
$global:transfers[$_.FullName] = Join-Path (Join-Path $staging.FullName $item.Parent) $item.Path
69-
70-
Copy-Item $_.FullName -Destination $global:transfers[$_.FullName] -Force -Recurse
64+
Copy-Item $_.FullName -Destination (Join-Path (Join-Path $staging.FullName $item.Parent) $item.Path) -Force -Recurse
65+
}
66+
67+
# Exception to counter weird copy bug
68+
if ($item.Name -eq "PSFTests")
69+
{
70+
$source = "$($staging.FullName)\$($item.Name)\functions"
71+
$destination = (Join-Path (Join-Path $staging.FullName $item.Parent) $item.Path)
72+
Copy-Item -Path $source -Destination $destination -Recurse -Force
7173
}
7274
}
7375
$listToProcess = $listToProcess | Where-Object { $_ -notin $processingThisTime }

0 commit comments

Comments
 (0)