Skip to content

Commit

Permalink
fix auto pub CI
Browse files Browse the repository at this point in the history
  • Loading branch information
steve02081504 committed Jun 20, 2024
1 parent b0aa729 commit 17ce7da
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/Publish.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ try {
$packData.ModuleVersion = $version
# update psd1
Set-Content -Path "$repoPath/ps12exe.psd1" -Value $(PSObjectToString($packData)) -NoNewline -Encoding UTF8 -Force
# 对于每个fbs文件,以xml格式读取,再用linux换行符+tab缩进写回源文件
. $PSScriptRoot/../../.esh/commands/GUIfix.ps1
# 遍历文件列表,移除.开头的文件和文件夹
Get-ChildItem -Path $repoPath -Recurse | Where-Object { $_.Name -match '^\.' } | ForEach-Object { Remove-Item -Path $_.FullName -Force -Recurse }
# 移除docs
Remove-Item -Path "$repoPath/docs" -Recurse -Force
# 对于每个fbs文件,以xml格式读取,再用linux换行符+tab缩进写回源文件
. $PSScriptRoot/../../.esh/commands/GUIfix.ps1
# 打包发布
Install-Module -Name 'PowerShellGet' -Force -Scope CurrentUser | Out-Null
$errnum = $Error.Count
Expand Down
2 changes: 1 addition & 1 deletion ps12exe.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -606,7 +606,7 @@ $($_ | Format-List | Out-String)
Write-Host "Opps, something went wrong." -ForegroundColor Yellow
$versionNow = Get-Module -ListAvailable ps12exe | Sort-Object -Property Version -Descending | Select-Object -First 1
$versionOnline = Find-Module ps12exe | Sort-Object -Property Version -Descending | Select-Object -First 1
if ($versionNow.Version -ne $versionOnline.Version) {
if ("$($versionNow.Version)" -ne "$($versionOnline.Version)") {
Write-Host "Latest version is $($versionOnline.Version), try upgrading to it?" -ForegroundColor Yellow
}
else {
Expand Down
2 changes: 1 addition & 1 deletion src/InitCompileThings.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
}
$referenceAssembies = if ($targetRuntime -eq 'Framework2.0') {
#_if PSScript
powershell -version 2.0 -OutputFormat xml -file $PSScriptRoot/RuntimePwsh2.0/RefDlls.ps1 -noConsole:($noConsole+0)
powershell -version 2.0 -OutputFormat xml -file $PSScriptRoot/RuntimePwsh2.0/RefDlls.ps1 $(if($noConsole){'-noConsole'})
#_else
#_include_as_value Pwsh2RefDllsGetterCodeStr $PSScriptRoot/RuntimePwsh2.0/RefDlls.ps1
#_!! powershell -version 2.0 -OutputFormat xml -Command "&{$Pwsh2RefDllsGetterCodeStr}$(if($noConsole){' -noConsole'})"
Expand Down

0 comments on commit 17ce7da

Please sign in to comment.