Skip to content

Commit

Permalink
Fix the publish.ps1
Browse files Browse the repository at this point in the history
  • Loading branch information
hcoona committed Aug 13, 2020
1 parent cc953fe commit 8eeee5b
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions dev-support/bin/publish.ps1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
param(
[string] $Configuration = "Release",
[switch] $SkipDos2Unix,
[switch] $SkipUnix2Dos,
[switch] $SkipGriPlc,
[switch] $SkipGriServer,
[switch] $SkipGriWpf
Expand All @@ -10,6 +10,8 @@ $ErrorActionPreference = "Stop"

$EnlistmentRoot = [System.IO.Path]::GetDirectoryName([System.IO.Path]::GetDirectoryName($PSScriptRoot))
$OutputRoot = (Join-Path $EnlistmentRoot "output")
$UnixToDosExec = (Join-Path $EnlistmentRoot "dev-support\bin\vs2019_dos2unix\unix2dos.exe")

if ([System.IO.Directory]::Exists($OutputRoot)) {
Remove-Item -Path $OutputRoot -Recurse -Force
}
Expand Down Expand Up @@ -48,9 +50,9 @@ if (-not $SkipGriWpf) {
}
}

if (-not $SkipDos2Unix) {
Get-ChildItem -Path (Join-Path $OutputRoot "GeothermalResearchInstitute") `-Filter "*.ini" -Recurse `
| ForEach-Object{ & "$UnixToDosExec" --add-bom $_.FullName }
if (-not $SkipUnix2Dos) {
Get-ChildItem -Path (Join-Path $OutputRoot "GeothermalResearchInstitute") -Filter "*.ini" -Recurse `
| ForEach-Object{ & $UnixToDosExec --add-bom $_.FullName }
}

New-Item -Path (Join-Path $OutputRoot "GeothermalResearchInstitute/docs") -Type Directory
Expand Down

0 comments on commit 8eeee5b

Please sign in to comment.