Skip to content

Commit 5d8bbe7

Browse files
author
Andrew Omondi
committed
chore: fix bug in script
1 parent 1b67540 commit 5d8bbe7

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scripts/copyFilesOnBuild.ps1

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,12 @@ Param(
1515
[Parameter(Mandatory = $true)][string]$inputPath
1616
)
1717

18+
$fullPath = (Get-Item $inputPath).FullName
1819
$parentDirectory = (Get-Item $inputPath).Parent
1920
Push-Location $inputPath
2021

2122
Get-ChildItem '*' -Filter *.java -recurse | ForEach-Object {
22-
$TargetDirectory = $_.DirectoryName.Replace($inputPath, "")
23+
$TargetDirectory = $_.DirectoryName.Replace($fullPath, "")
2324
$TargetPath = Join-Path -Path $parentDirectory -ChildPath $TargetDirectory
2425
If (!(Test-Path $TargetPath)) {
2526
mkdir $TargetPath | out-null

0 commit comments

Comments
 (0)