mirror of
https://github.com/mRemoteNG/mRemoteNG.git
synced 2026-02-17 14:07:46 +08:00
modify build scripts for appveyor
This commit is contained in:
@@ -10,6 +10,10 @@
|
|||||||
<Configurations>Debug;Release;Debug Portable;Release Portable</Configurations>
|
<Configurations>Debug;Release;Debug Portable;Release Portable</Configurations>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Portable|x64'">
|
||||||
|
<Optimize>True</Optimize>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="AWSSDK.Core" Version="3.7.106.6" />
|
<PackageReference Include="AWSSDK.Core" Version="3.7.106.6" />
|
||||||
<PackageReference Include="AWSSDK.EC2" Version="3.7.128.3" />
|
<PackageReference Include="AWSSDK.EC2" Version="3.7.128.3" />
|
||||||
|
|||||||
@@ -8,7 +8,16 @@ if ($IsAppVeyor) {
|
|||||||
#$CURRENT_GITHUB_USER = $env:APPVEYOR_REPO_NAME.Split("/")[0]
|
#$CURRENT_GITHUB_USER = $env:APPVEYOR_REPO_NAME.Split("/")[0]
|
||||||
Install-Module -Name PowerShellForGitHub -Scope CurrentUser
|
Install-Module -Name PowerShellForGitHub -Scope CurrentUser
|
||||||
Set-GitHubConfiguration -DisableTelemetry
|
Set-GitHubConfiguration -DisableTelemetry
|
||||||
$PSDefaultParameterValues["*-GitHub*:AccessToken"] = "$env:ACCESS_TOKEN"
|
$PSDefaultParameterValues["*-GitHub*:AccessToken"] = "$env:ACCESS_TOKEN"
|
||||||
|
#New-Item -Path "$Env:APPVEYOR_BUILD_FOLDER\Release" -ItemType Directory -Force
|
||||||
|
}
|
||||||
|
|
||||||
|
function New-TemporaryDirectory {
|
||||||
|
$parent = [System.IO.Path]::GetTempPath()
|
||||||
|
[string] $name = [System.Guid]::NewGuid()
|
||||||
|
$fullTempPath = (Join-Path $parent $name)
|
||||||
|
New-Item -ItemType Directory -Path $fullTempPath
|
||||||
|
return $fullTempPath
|
||||||
}
|
}
|
||||||
|
|
||||||
Function ConvertFrom-Base64($base64) {
|
Function ConvertFrom-Base64($base64) {
|
||||||
|
|||||||
81
Tools/postbuild.ps1
Normal file
81
Tools/postbuild.ps1
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
param (
|
||||||
|
[string]
|
||||||
|
[Parameter(Mandatory=$true)]
|
||||||
|
$SolutionDir,
|
||||||
|
|
||||||
|
[string]
|
||||||
|
[Parameter(Mandatory=$true)]
|
||||||
|
$TargetDir,
|
||||||
|
|
||||||
|
[string]
|
||||||
|
[Parameter(Mandatory=$true)]
|
||||||
|
$TargetFileName,
|
||||||
|
|
||||||
|
[string]
|
||||||
|
[Parameter(Mandatory=$true)]
|
||||||
|
$ConfigurationName,
|
||||||
|
|
||||||
|
[string]
|
||||||
|
$CertificatePath,
|
||||||
|
|
||||||
|
[string]
|
||||||
|
$CertificatePassword,
|
||||||
|
|
||||||
|
[string[]]
|
||||||
|
$ExcludeFromSigning
|
||||||
|
)
|
||||||
|
|
||||||
|
. "$PSScriptRoot\github_functions.ps1"
|
||||||
|
|
||||||
|
Write-Output ""
|
||||||
|
Write-Output "+============================================================+"
|
||||||
|
Write-Output "| Beginning mRemoteNG Post Build |"
|
||||||
|
Write-Output "+============================================================+"
|
||||||
|
Format-Table -AutoSize -Wrap -InputObject @{
|
||||||
|
"SolutionDir" = $SolutionDir
|
||||||
|
"TargetDir" = $TargetDir
|
||||||
|
"TargetFileName" = $TargetFileName
|
||||||
|
"ConfigurationName" = $ConfigurationName
|
||||||
|
"CertificatePath" = $CertificatePath
|
||||||
|
"ExcludeFromSigning" = $ExcludeFromSigning
|
||||||
|
}
|
||||||
|
|
||||||
|
$IsAppVeyor = !([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))
|
||||||
|
|
||||||
|
if ( $ConfigurationName -match "Debug" -and -not $IsAppVeyor ) {return; } #skip when Debug local developer build
|
||||||
|
if ( $env:APPVEYOR_PROJECT_NAME -match "(CI)" -and -not $IsAppVeyor ) {return; } #skip when AppVeyor (CI) build
|
||||||
|
|
||||||
|
$dstPath = "$($SolutionDir)Release"
|
||||||
|
New-Item -Path $dstPath -ItemType Directory -Force
|
||||||
|
|
||||||
|
# $RunInstaller = $TargetDir -match "\\mRemoteNGInstaller\\Installer\\bin\\"
|
||||||
|
# $RunPortable = ( ($Targetdir -match "\\mRemoteNG\\bin\\") -and -not ($TargetDir -match "\\mRemoteNGInstaller\\Installer\\bin\\") )
|
||||||
|
|
||||||
|
Write-Output "-Begin Release Portable"
|
||||||
|
|
||||||
|
if ( ($ConfigurationName -match "Release") -and ($env:APPVEYOR_PROJECT_NAME -notcontains "(CI)") ) {
|
||||||
|
|
||||||
|
& "$PSScriptRoot\tidy_files_for_release.ps1" -TargetDir $TargetDir -ConfigurationName $ConfigurationName
|
||||||
|
|
||||||
|
& "$PSScriptRoot\sign_binaries.ps1" -TargetDir $TargetDir -CertificatePath $CertificatePath -CertificatePassword $CertificatePassword -ConfigurationName $ConfigurationName -Exclude $ExcludeFromSigning -SolutionDir $SolutionDir
|
||||||
|
|
||||||
|
& "$PSScriptRoot\verify_binary_signatures.ps1" -TargetDir $TargetDir -ConfigurationName $ConfigurationName -CertificatePath $CertificatePath -SolutionDir $SolutionDir
|
||||||
|
|
||||||
|
& "$PSScriptRoot\zip_files.ps1" -SolutionDir $SolutionDir -TargetDir $TargetDir -ConfigurationName $ConfigurationName
|
||||||
|
|
||||||
|
if ( $IsAppVeyor -and (![string]::IsNullOrEmpty($env:WEBSITE_TARGET_OWNER)) -and (![string]::IsNullOrEmpty($env:WEBSITE_TARGET_REPOSITORY)) ) {
|
||||||
|
|
||||||
|
& "$PSScriptRoot\update_and_upload_website_release_json_file.ps1" -WebsiteTargetOwner $env:WEBSITE_TARGET_OWNER -WebsiteTargetRepository $env:WEBSITE_TARGET_REPOSITORY -PreTagName $env:NightlyBuildTagName -TagName $env:APPVEYOR_BUILD_VERSION -ProjectName $env:APPVEYOR_PROJECT_NAME
|
||||||
|
|
||||||
|
& "$PSScriptRoot\create_upg_chk_files.ps1" -WebsiteTargetOwner $env:WEBSITE_TARGET_OWNER -WebsiteTargetRepository $env:WEBSITE_TARGET_REPOSITORY -PreTagName $env:NightlyBuildTagName -TagName $env:APPVEYOR_BUILD_VERSION -ProjectName $env:APPVEYOR_PROJECT_NAME
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
Write-Output "-End Release Portable"
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Write-Output "End mRemoteNG Post Build"
|
||||||
|
Write-Output ""
|
||||||
|
|
||||||
@@ -40,19 +40,24 @@ Format-Table -AutoSize -Wrap -InputObject @{
|
|||||||
"ExcludeFromSigning" = $ExcludeFromSigning
|
"ExcludeFromSigning" = $ExcludeFromSigning
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$IsAppVeyor = !([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))
|
||||||
|
|
||||||
& "$PSScriptRoot\sign_binaries.ps1" -TargetDir $TargetDir -CertificatePath $CertificatePath -CertificatePassword $CertificatePassword -ConfigurationName $ConfigurationName -Exclude $ExcludeFromSigning -SolutionDir $SolutionDir
|
if ( $IsAppVeyor -and ($ConfigurationName.ToUpper() -match "RELEASE") -and (($env:APPVEYOR_PROJECT_NAME).ToUpper() -notcontains "(CI)") ) {
|
||||||
|
|
||||||
& "$PSScriptRoot\verify_binary_signatures.ps1" -TargetDir $TargetDir -ConfigurationName $ConfigurationName -CertificatePath $CertificatePath -SolutionDir $SolutionDir
|
& "$PSScriptRoot\sign_binaries.ps1" -TargetDir $TargetDir -CertificatePath $CertificatePath -CertificatePassword $CertificatePassword -ConfigurationName $ConfigurationName -Exclude $ExcludeFromSigning -SolutionDir $SolutionDir
|
||||||
|
|
||||||
& "$PSScriptRoot\rename_and_copy_installer.ps1" -SolutionDir $SolutionDir -BuildConfiguration $ConfigurationName.Trim()
|
|
||||||
|
|
||||||
if ( ![string]::IsNullOrEmpty($env:WEBSITE_TARGET_OWNER) -and ![string]::IsNullOrEmpty($env:WEBSITE_TARGET_REPOSITORY) ) {
|
|
||||||
|
|
||||||
|
& "$PSScriptRoot\verify_binary_signatures.ps1" -TargetDir $TargetDir -ConfigurationName $ConfigurationName -CertificatePath $CertificatePath -SolutionDir $SolutionDir
|
||||||
|
|
||||||
|
& "$PSScriptRoot\rename_and_copy_installer.ps1" -SolutionDir $SolutionDir -BuildConfiguration $ConfigurationName.Trim()
|
||||||
|
|
||||||
& "$PSScriptRoot\create_upg_chk_files.ps1" -WebsiteTargetOwner $env:WEBSITE_TARGET_OWNER -WebsiteTargetRepository $env:WEBSITE_TARGET_REPOSITORY -PreTagName $env:NightlyBuildTagName -TagName $env:APPVEYOR_BUILD_VERSION -ProjectName $env:APPVEYOR_PROJECT_NAME
|
& "$PSScriptRoot\create_upg_chk_files.ps1" -WebsiteTargetOwner $env:WEBSITE_TARGET_OWNER -WebsiteTargetRepository $env:WEBSITE_TARGET_REPOSITORY -PreTagName $env:NightlyBuildTagName -TagName $env:APPVEYOR_BUILD_VERSION -ProjectName $env:APPVEYOR_PROJECT_NAME
|
||||||
|
|
||||||
& "$PSScriptRoot\update_and_upload_website_release_json_file.ps1" -WebsiteTargetOwner $env:WEBSITE_TARGET_OWNER -WebsiteTargetRepository $env:WEBSITE_TARGET_REPOSITORY -PreTagName $env:NightlyBuildTagName -TagName $env:APPVEYOR_BUILD_VERSION -ProjectName $env:APPVEYOR_PROJECT_NAME
|
& "$PSScriptRoot\update_and_upload_website_release_json_file.ps1" -WebsiteTargetOwner $env:WEBSITE_TARGET_OWNER -WebsiteTargetRepository $env:WEBSITE_TARGET_REPOSITORY -PreTagName $env:NightlyBuildTagName -TagName $env:APPVEYOR_BUILD_VERSION -ProjectName $env:APPVEYOR_PROJECT_NAME
|
||||||
|
|
||||||
|
& "$PSScriptRoot\update_and_upload_assemblyinfocs.ps1"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
Write-Output "End mRemoteNG Installer Post Build"
|
Write-Output "End mRemoteNG Installer Post Build"
|
||||||
Write-Output ""
|
Write-Output ""
|
||||||
|
|||||||
@@ -60,11 +60,22 @@ Format-Table -AutoSize -Wrap -InputObject @{
|
|||||||
#& "$PSScriptRoot\set_LargeAddressAware.ps1" -TargetDir $TargetDir -TargetFileName $TargetFileName
|
#& "$PSScriptRoot\set_LargeAddressAware.ps1" -TargetDir $TargetDir -TargetFileName $TargetFileName
|
||||||
#& "$PSScriptRoot\verify_LargeAddressAware.ps1" -TargetDir $TargetDir -TargetFileName $TargetFileName
|
#& "$PSScriptRoot\verify_LargeAddressAware.ps1" -TargetDir $TargetDir -TargetFileName $TargetFileName
|
||||||
|
|
||||||
|
if (!([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))) {
|
||||||
|
$postbuild_installer_executed = Get-ItemPropertyValue -Path 'HKLM:\SOFTWARE\AppVeyor_mRemoteNG' -Name postbuild_installer_executed
|
||||||
|
} else {
|
||||||
|
$postbuild_installer_executed = ""
|
||||||
|
}
|
||||||
|
|
||||||
|
write-host "-SolutionDir $SolutionDir -TargetDir $TargetDir -ConfigurationName $ConfigurationName "
|
||||||
|
|
||||||
& "$PSScriptRoot\tidy_files_for_release.ps1" -TargetDir $TargetDir -ConfigurationName $ConfigurationName
|
& "$PSScriptRoot\tidy_files_for_release.ps1" -TargetDir $TargetDir -ConfigurationName $ConfigurationName
|
||||||
|
|
||||||
& "$PSScriptRoot\sign_binaries.ps1" -TargetDir $TargetDir -CertificatePath $CertificatePath -CertificatePassword $CertificatePassword -ConfigurationName $ConfigurationName -Exclude $ExcludeFromSigning -SolutionDir $SolutionDir
|
if ($postbuild_installer_executed -ne "true" -or $env:postbuild_installer_executed -ne "true") {
|
||||||
|
|
||||||
& "$PSScriptRoot\verify_binary_signatures.ps1" -TargetDir $TargetDir -ConfigurationName $ConfigurationName -CertificatePath $CertificatePath -SolutionDir $SolutionDir
|
& "$PSScriptRoot\sign_binaries.ps1" -TargetDir $TargetDir -CertificatePath $CertificatePath -CertificatePassword $CertificatePassword -ConfigurationName $ConfigurationName -Exclude $ExcludeFromSigning -SolutionDir $SolutionDir
|
||||||
|
|
||||||
|
& "$PSScriptRoot\verify_binary_signatures.ps1" -TargetDir $TargetDir -ConfigurationName $ConfigurationName -CertificatePath $CertificatePath -SolutionDir $SolutionDir
|
||||||
|
}
|
||||||
|
|
||||||
& "$PSScriptRoot\zip_files.ps1" -SolutionDir $SolutionDir -TargetDir $TargetDir -ConfigurationName $ConfigurationName
|
& "$PSScriptRoot\zip_files.ps1" -SolutionDir $SolutionDir -TargetDir $TargetDir -ConfigurationName $ConfigurationName
|
||||||
|
|
||||||
|
|||||||
@@ -5,13 +5,17 @@
|
|||||||
$BuildConfiguration
|
$BuildConfiguration
|
||||||
)
|
)
|
||||||
|
|
||||||
|
$ErrorActionPreference = "Stop"
|
||||||
|
|
||||||
Write-Output ""
|
Write-Output ""
|
||||||
Write-Output " /===== Begin $($PSCmdlet.MyInvocation.MyCommand) =====/"
|
Write-Output " /===== Begin rename_and_copy_installer =====/"
|
||||||
|
|
||||||
$targetVersionedFile = "$SolutionDir\mRemoteNG\bin\x64\$BuildConfiguration\mRemoteNG.exe"
|
$targetVersionedFile = "$SolutionDir\mRemoteNG\bin\x64\$BuildConfiguration\mRemoteNG.exe"
|
||||||
#$fileversion = &"$SolutionDir\Tools\exes\sigcheck.exe" /accepteula -q -n $targetVersionedFile
|
#$fileversion = &"$SolutionDir\Tools\exes\sigcheck.exe" /accepteula -q -n $targetVersionedFile
|
||||||
#$prodversion = ((Get-Item -Path $targetVersionedFile).VersionInfo | Select-Object -Property ProductVersion)."ProductVersion"
|
#$prodversion = ((Get-Item -Path $targetVersionedFile).VersionInfo | Select-Object -Property ProductVersion)."ProductVersion"
|
||||||
$fileversion = ((Get-Item -Path $targetVersionedFile).VersionInfo | Select-Object -Property FileVersion)."FileVersion"
|
$fileversion = ((Get-Item -Path $targetVersionedFile).VersionInfo | Select-Object -Property FileVersion)."FileVersion"
|
||||||
|
|
||||||
|
Write-Output "fileversion: $fileversion"
|
||||||
$msiversion = $fileversion
|
$msiversion = $fileversion
|
||||||
|
|
||||||
# determine update channel
|
# determine update channel
|
||||||
@@ -26,9 +30,10 @@ if ($env:APPVEYOR_PROJECT_NAME -match "(Nightly)") {
|
|||||||
} else {
|
} else {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$dstPath = "$($SolutionDir)Release"
|
||||||
|
New-Item -Path $dstPath -ItemType Directory -Force
|
||||||
$srcMsi = $SolutionDir + "mRemoteNGInstaller\Installer\bin\x64\$BuildConfiguration\en-US\mRemoteNG-Installer.msi"
|
$srcMsi = $SolutionDir + "mRemoteNGInstaller\Installer\bin\x64\$BuildConfiguration\en-US\mRemoteNG-Installer.msi"
|
||||||
#$dstMsi = $SolutionDir + "Release\mRemoteNG-Installer-" + $msiversion + ".msi"
|
$dstMsi = $dstPath + "\mRemoteNG-Installer-" + $msiversion + ".msi"
|
||||||
$dstMsi = $SolutionDir + "mRemoteNG\bin\x64\$BuildConfiguration\mRemoteNG-Installer-" + $msiversion + ".msi"
|
|
||||||
#$srcSymbols = $SolutionDir + "mRemoteNGInstaller\Installer\bin\x64\$BuildConfiguration\en-US\mRemoteNG-Installer-Symbols*.zip"
|
#$srcSymbols = $SolutionDir + "mRemoteNGInstaller\Installer\bin\x64\$BuildConfiguration\en-US\mRemoteNG-Installer-Symbols*.zip"
|
||||||
#$dstSymbols = $SolutionDir + "Release\mRemoteNG-Installer-Symbols-" + $msiversion + ".zip"
|
#$dstSymbols = $SolutionDir + "Release\mRemoteNG-Installer-Symbols-" + $msiversion + ".zip"
|
||||||
|
|
||||||
@@ -39,15 +44,18 @@ Write-Output ""
|
|||||||
# Copy file
|
# Copy file
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
Copy-Item $srcMsi -Destination $dstMsi -Force -errorAction stop
|
Copy-Item $srcMsi -Destination $dstMsi -Force -ErrorAction Stop
|
||||||
|
#Copy-Item $srcSymbols -Destination $dstSymbols -Force -ErrorAction Stop
|
||||||
Write-Host " [Success!]" -ForegroundColor green
|
Write-Host " [Success!]" -ForegroundColor green
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
Write-Host " [Failure!]" -ForegroundColor red
|
Write-Host " [Failure!]" -ForegroundColor red
|
||||||
|
Write-Output $Error[0]
|
||||||
|
$PSCmdlet.ThrowTerminatingError()
|
||||||
}
|
}
|
||||||
#Copy-Item $srcSymbols -Destination $dstSymbols -Force
|
|
||||||
|
|
||||||
Write-Output ""
|
Write-Output ""
|
||||||
Write-Output " /===== End $($PSCmdlet.MyInvocation.MyCommand) =====/"
|
Write-Output " /===== End rename_and_copy_installer.ps1 =====/"
|
||||||
Write-Output ""
|
Write-Output ""
|
||||||
|
|||||||
@@ -31,59 +31,73 @@ $timeserver = "http://timestamp.verisign.com/scripts/timstamp.dll"
|
|||||||
|
|
||||||
$IsAppVeyor = !([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))
|
$IsAppVeyor = !([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))
|
||||||
|
|
||||||
# validate release versions and if the certificate value was passed
|
try {
|
||||||
if ($ConfigurationName -match "Release" -And ($CertificatePath)) {
|
# validate release versions and if the certificate value was passed
|
||||||
|
if ($ConfigurationName -match "Release" -And ($CertificatePath)) {
|
||||||
|
|
||||||
if($IsAppVeyor) {
|
if($IsAppVeyor) {
|
||||||
$CertificatePath = Join-Path -Path $SolutionDir -ChildPath $CertificatePath
|
$CertificatePath = Join-Path -Path $SolutionDir -ChildPath $CertificatePath
|
||||||
|
# Write-Output "Decrypt Cert"
|
||||||
|
# & appveyor-tools\secure-file -decrypt "$($Env:cert_path).enc" -secret "$Env:cert_decrypt_pwd"
|
||||||
|
# if(-Not (Test-Path $Env:cert_path)) {
|
||||||
|
# Write-Output "decrypt cert does not exist..."
|
||||||
|
# Throw "Could not decrypt cert"
|
||||||
|
# }
|
||||||
|
# Write-Output "Restoring NuGets"
|
||||||
|
}
|
||||||
|
|
||||||
|
# make sure the cert is actually available
|
||||||
|
if ($CertificatePath -eq "" -or !(Test-Path -Path $CertificatePath -PathType Leaf))
|
||||||
|
{
|
||||||
|
Write-Output "Certificate is not present - we won't sign files."
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($CertificatePassword -eq "") {
|
||||||
|
Write-Output "No certificate password was provided - we won't sign files."
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$certKeyStore = [System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::MachineKeySet
|
||||||
|
$cert = New-Object System.Security.Cryptography.X509Certificates.X509Certificate2($CertificatePath, $CertificatePassword, $certKeyStore) -ErrorAction Stop
|
||||||
|
} catch {
|
||||||
|
Write-Output "Error loading certificate file - we won't sign files."
|
||||||
|
Write-Output $Error[0]
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
# Sign MSI if we are building a release version and the certificate is available
|
||||||
|
Write-Output "Signing Binaries"
|
||||||
|
Write-Output "Getting files from path: $TargetDir"
|
||||||
|
$signableFiles = Get-ChildItem -Path $TargetDir -Recurse | ?{$_.Extension -match "dll|exe|msi"} | ?{$Exclude -notcontains $_.Name}
|
||||||
|
|
||||||
|
$excluded_files = Get-ChildItem -Path $TargetDir -Recurse | ?{$_.Extension -match "dll|exe|msi"} | ?{$Exclude -contains $_.Name}
|
||||||
|
$excluded_files | ForEach-Object `
|
||||||
|
-Begin { Write-Output "The following files were excluded from signing due to being on the exclusion list:" } `
|
||||||
|
-Process { Write-Output "-- $($_.FullName)" }
|
||||||
|
|
||||||
|
Write-Output "Signable files count: $($signableFiles.Count)"
|
||||||
|
|
||||||
|
|
||||||
|
foreach ($file in $signableFiles) {
|
||||||
|
Set-AuthenticodeSignature -Certificate $cert -TimestampServer $timeserver -IncludeChain all -FilePath $file.FullName
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# Release certificate
|
||||||
|
if ($null -ne $cert) {
|
||||||
|
$cert.Dispose()
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
Write-Output "This is not a release build or CertificatePath wasn't provided - we won't sign files."
|
||||||
|
Write-Output "Config: $($ConfigurationName)`tCertPath: $($CertificatePath)"
|
||||||
}
|
}
|
||||||
|
|
||||||
# make sure the cert is actually available
|
}
|
||||||
if ($CertificatePath -eq "" -or !(Test-Path -Path $CertificatePath -PathType Leaf))
|
catch {
|
||||||
{
|
Write-Output $Error[0]
|
||||||
Write-Output "Certificate is not present - we won't sign files."
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($CertificatePassword -eq "") {
|
|
||||||
Write-Output "No certificate password was provided - we won't sign files."
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
|
||||||
$certKeyStore = [System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::MachineKeySet
|
|
||||||
$cert = New-Object System.Security.Cryptography.X509Certificates.X509Certificate2($CertificatePath, $CertificatePassword, $certKeyStore) -ErrorAction Stop
|
|
||||||
} catch {
|
|
||||||
Write-Output "Error loading certificate file - we won't sign files."
|
|
||||||
Write-Output $Error[0]
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
# Sign MSI if we are building a release version and the certificate is available
|
|
||||||
Write-Output "Signing Binaries"
|
|
||||||
Write-Output "Getting files from path: $TargetDir"
|
|
||||||
$signableFiles = Get-ChildItem -Path $TargetDir -Recurse | ?{$_.Extension -match "dll|exe|msi"} | ?{$Exclude -notcontains $_.Name}
|
|
||||||
|
|
||||||
$excluded_files = Get-ChildItem -Path $TargetDir -Recurse | ?{$_.Extension -match "dll|exe|msi"} | ?{$Exclude -contains $_.Name}
|
|
||||||
$excluded_files | ForEach-Object `
|
|
||||||
-Begin { Write-Output "The following files were excluded from signing due to being on the exclusion list:" } `
|
|
||||||
-Process { Write-Output "-- $($_.FullName)" }
|
|
||||||
|
|
||||||
Write-Output "Signable files count: $($signableFiles.Count)"
|
|
||||||
|
|
||||||
|
|
||||||
foreach ($file in $signableFiles) {
|
|
||||||
Set-AuthenticodeSignature -Certificate $cert -TimestampServer $timeserver -IncludeChain all -FilePath $file.FullName
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
# Release certificate
|
|
||||||
if ($null -ne $cert) {
|
|
||||||
$cert.Dispose()
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
Write-Output "This is not a release build or CertificatePath wasn't provided - we won't sign files."
|
|
||||||
Write-Output "Config: $($ConfigurationName)`tCertPath: $($CertificatePath)"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Write-Output "End $($PSCmdlet.MyInvocation.MyCommand)"
|
||||||
Write-Output ""
|
Write-Output ""
|
||||||
|
|||||||
52
Tools/update_and_upload_assemblyinfocs.ps1
Normal file
52
Tools/update_and_upload_assemblyinfocs.ps1
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
#Requires -Version 4.0
|
||||||
|
|
||||||
|
Write-Output ""
|
||||||
|
Write-Output "===== Begin $($PSCmdlet.MyInvocation.MyCommand) ====="
|
||||||
|
|
||||||
|
$MainRepository = $Env:APPVEYOR_REPO_NAME.Split("/\")[1]
|
||||||
|
$IsAppVeyor = !([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))
|
||||||
|
|
||||||
|
|
||||||
|
if ($IsAppVeyor) {
|
||||||
|
|
||||||
|
# determine update channel
|
||||||
|
if ($env:APPVEYOR_PROJECT_NAME -match "(Nightly)") {
|
||||||
|
Write-Output "UpdateChannel = Nightly"
|
||||||
|
$UpdateChannel = "Nightly"
|
||||||
|
$ModifiedTagName = "$PreTagName-$TagName-NB"
|
||||||
|
} elseif ($env:APPVEYOR_PROJECT_NAME -match "(Preview)") {
|
||||||
|
Write-Output "UpdateChannel = Preview"
|
||||||
|
$UpdateChannel = "Preview"
|
||||||
|
$ModifiedTagName = "v$TagName-PB"
|
||||||
|
} elseif ($env:APPVEYOR_PROJECT_NAME -match "(Stable)") {
|
||||||
|
Write-Output "UpdateChannel = Stable"
|
||||||
|
$UpdateChannel = "Stable"
|
||||||
|
$ModifiedTagName = "v" + $TagName.Split("-")[0]
|
||||||
|
} else {
|
||||||
|
$UpdateChannel = ""
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($UpdateChannel -ne "" -and $MainRepository -ne "" ) {
|
||||||
|
|
||||||
|
# commit AssemblyInfo.cs change
|
||||||
|
Write-Output "publish AssemblyInfo.cs"
|
||||||
|
|
||||||
|
$buildFolder = Join-Path -Path $PSScriptRoot -ChildPath "..\" -Resolve -ErrorAction Ignore
|
||||||
|
|
||||||
|
if (Test-Path -Path "$buildFolder\mRemoteNG\Properties\AssemblyInfo.cs") {
|
||||||
|
|
||||||
|
$assemblyinfocs_content = [System.String]::Join("`r`n", (Get-Content "$buildFolder\mRemoteNG\Properties\AssemblyInfo.cs"))
|
||||||
|
|
||||||
|
Set-GitHubContent -OwnerName $MainRepository -RepositoryName $MainRepository -Path "mRemoteNG\Properties\AssemblyInfo.cs" -CommitMessage "AssemblyInfo.cs updated for $UpdateChannel $ModifiedTagName" -Content $assemblyinfocs_content -BranchName main
|
||||||
|
|
||||||
|
Write-Output "publish completed"
|
||||||
|
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
Write-Output "Source folder not found"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Write-Output "End $($PSCmdlet.MyInvocation.MyCommand)"
|
||||||
|
Write-Output ""
|
||||||
@@ -44,128 +44,133 @@ if ($env:APPVEYOR_PROJECT_NAME -match "(Nightly)") {
|
|||||||
$UpdateChannel = ""
|
$UpdateChannel = ""
|
||||||
}
|
}
|
||||||
|
|
||||||
#$buildFolder = Join-Path -Path $PSScriptRoot -ChildPath "..\mRemoteNG\bin\x64\Release" -Resolve -ErrorAction Ignore
|
$IsAppVeyor = !([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))
|
||||||
$ReleaseFolder = Join-Path -Path $PSScriptRoot -ChildPath "..\Release" -Resolve
|
|
||||||
|
|
||||||
if ($UpdateChannel -ne "" -and $ReleaseFolder -ne "" -and $MainRepository -ne "" -and $WebsiteTargetOwner -ne "" -and $WebsiteTargetRepository -ne "" ) {
|
if ($IsAppVeyor) {
|
||||||
|
|
||||||
$published_at = (Get-Date).ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ")
|
#$buildFolder = Join-Path -Path $PSScriptRoot -ChildPath "..\mRemoteNG\bin\x64\Release" -Resolve -ErrorAction Ignore
|
||||||
|
$ReleaseFolder = Join-Path -Path $PSScriptRoot -ChildPath "..\Release" -Resolve
|
||||||
# get releases.json from github
|
|
||||||
$releases_json = Get-GitHubContent -OwnerName $WebsiteTargetOwner -RepositoryName $WebsiteTargetRepository -Path _data\releases.json
|
|
||||||
ConvertFrom-Base64($releases_json.content) | Out-File -FilePath "$ReleaseFolder\releases.json"
|
|
||||||
$websiteJsonReleaseFile = Get-ChildItem -Path "$ReleaseFolder\releases.json"
|
|
||||||
|
|
||||||
# installer
|
if ($UpdateChannel -ne "" -and $ReleaseFolder -ne "" -and $MainRepository -ne "" -and $WebsiteTargetOwner -ne "" -and $WebsiteTargetRepository -ne "" ) {
|
||||||
$msiFile = Get-ChildItem -Path "$ReleaseFolder\*.msi" | Sort-Object LastWriteTime | Select-Object -last 1
|
|
||||||
if (![string]::IsNullOrEmpty($msiFile)) {
|
$published_at = (Get-Date).ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ")
|
||||||
Write-Output "UpdateChannel: $UpdateChannel"
|
|
||||||
Write-Output "msiFile: $msiFile"
|
# get releases.json from github
|
||||||
$checksum = (Get-FileHash $msiFile -Algorithm SHA512).Hash
|
$releases_json = Get-GitHubContent -OwnerName $WebsiteTargetOwner -RepositoryName $WebsiteTargetRepository -Path _data\releases.json
|
||||||
$file_size = (Get-ChildItem $msiFile).Length
|
ConvertFrom-Base64($releases_json.content) | Out-File -FilePath "$ReleaseFolder\releases.json"
|
||||||
$a = Get-Content $websiteJsonReleaseFile | ConvertFrom-Json
|
$websiteJsonReleaseFile = Get-ChildItem -Path "$ReleaseFolder\releases.json"
|
||||||
switch ($UpdateChannel) {
|
|
||||||
"Nightly" {
|
# installer
|
||||||
$GithubTag = "$((Get-Date).ToUniversalTime().ToString("yyyyMMdd"))-$TagName-NB"
|
$msiFile = Get-ChildItem -Path "$ReleaseFolder\*.msi" | Sort-Object LastWriteTime | Select-Object -last 1
|
||||||
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
if (![string]::IsNullOrEmpty($msiFile)) {
|
||||||
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($msiFile.Name)"
|
Write-Output "UpdateChannel: $UpdateChannel"
|
||||||
$a.nightlybuild.name = "v$TagName-NB"
|
Write-Output "msiFile: $msiFile"
|
||||||
$a.nightlybuild.published_at = $published_at
|
$checksum = (Get-FileHash $msiFile -Algorithm SHA512).Hash
|
||||||
$a.nightlybuild.html_url = $html_url
|
$file_size = (Get-ChildItem $msiFile).Length
|
||||||
$a.nightlybuild.assets.installer.browser_download_url = $browser_download_url
|
$a = Get-Content $websiteJsonReleaseFile | ConvertFrom-Json
|
||||||
$a.nightlybuild.assets.installer.checksum = $checksum
|
switch ($UpdateChannel) {
|
||||||
$a.nightlybuild.assets.installer.size = $file_size
|
"Nightly" {
|
||||||
break
|
$GithubTag = "$((Get-Date).ToUniversalTime().ToString("yyyyMMdd"))-$TagName-NB"
|
||||||
}
|
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
||||||
"Preview" {
|
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($msiFile.Name)"
|
||||||
$GithubTag = "$TagName-PB"
|
$a.nightlybuild.name = "v$TagName-NB"
|
||||||
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
$a.nightlybuild.published_at = $published_at
|
||||||
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($msiFile.Name)"
|
$a.nightlybuild.html_url = $html_url
|
||||||
$a.prerelease.name = "v$TagName-PB"
|
$a.nightlybuild.assets.installer.browser_download_url = $browser_download_url
|
||||||
$a.prerelease.published_at = $published_at
|
$a.nightlybuild.assets.installer.checksum = $checksum
|
||||||
$a.prerelease.html_url = $html_url
|
$a.nightlybuild.assets.installer.size = $file_size
|
||||||
$a.prerelease.assets.installer.browser_download_url = $browser_download_url
|
break
|
||||||
$a.prerelease.assets.installer.checksum = $checksum
|
}
|
||||||
$a.prerelease.assets.installer.size = $file_size
|
"Preview" {
|
||||||
break
|
$GithubTag = "$TagName-PB"
|
||||||
}
|
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
||||||
"Stable" {
|
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($msiFile.Name)"
|
||||||
$GithubTag = "$TagName"
|
$a.prerelease.name = "v$TagName-PB"
|
||||||
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
$a.prerelease.published_at = $published_at
|
||||||
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($msiFile.Name)"
|
$a.prerelease.html_url = $html_url
|
||||||
$a.stable.name = "v$TagName"
|
$a.prerelease.assets.installer.browser_download_url = $browser_download_url
|
||||||
$a.stable.published_at = $published_at
|
$a.prerelease.assets.installer.checksum = $checksum
|
||||||
$a.stable.html_url = $html_url
|
$a.prerelease.assets.installer.size = $file_size
|
||||||
$a.stable.assets.installer.browser_download_url = $browser_download_url
|
break
|
||||||
$a.stable.assets.installer.checksum = $checksum
|
}
|
||||||
$a.stable.assets.installer.size = $file_size
|
"Stable" {
|
||||||
break
|
$GithubTag = "$TagName"
|
||||||
|
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
||||||
|
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($msiFile.Name)"
|
||||||
|
$a.stable.name = "v$TagName"
|
||||||
|
$a.stable.published_at = $published_at
|
||||||
|
$a.stable.html_url = $html_url
|
||||||
|
$a.stable.assets.installer.browser_download_url = $browser_download_url
|
||||||
|
$a.stable.assets.installer.checksum = $checksum
|
||||||
|
$a.stable.assets.installer.size = $file_size
|
||||||
|
break
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
# portable
|
# portable
|
||||||
$zipFile = Get-ChildItem -Path "$ReleaseFolder\*.zip" -Exclude "*-symbols-*.zip" | Sort-Object LastWriteTime | Select-Object -last 1
|
$zipFile = Get-ChildItem -Path "$ReleaseFolder\*.zip" -Exclude "*-symbols-*.zip" | Sort-Object LastWriteTime | Select-Object -last 1
|
||||||
if (![string]::IsNullOrEmpty($zipFile)) {
|
if (![string]::IsNullOrEmpty($zipFile)) {
|
||||||
Write-Output "UpdateChannel: $UpdateChannel"
|
Write-Output "UpdateChannel: $UpdateChannel"
|
||||||
Write-Output "zipFile: $zipFile"
|
Write-Output "zipFile: $zipFile"
|
||||||
$checksum = (Get-FileHash $zipFile -Algorithm SHA512).Hash
|
$checksum = (Get-FileHash $zipFile -Algorithm SHA512).Hash
|
||||||
$file_size = (Get-ChildItem $zipFile).Length
|
$file_size = (Get-ChildItem $zipFile).Length
|
||||||
$a = Get-Content $websiteJsonReleaseFile | ConvertFrom-Json
|
$a = Get-Content $websiteJsonReleaseFile | ConvertFrom-Json
|
||||||
switch ($UpdateChannel) {
|
switch ($UpdateChannel) {
|
||||||
"Nightly" {
|
"Nightly" {
|
||||||
$GithubTag = "$((Get-Date).ToUniversalTime().ToString("yyyyMMdd"))-$TagName-NB"
|
$GithubTag = "$((Get-Date).ToUniversalTime().ToString("yyyyMMdd"))-$TagName-NB"
|
||||||
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
||||||
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($zipFile.Name)"
|
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($zipFile.Name)"
|
||||||
$a.nightlybuild.name = "v$TagName-NB"
|
$a.nightlybuild.name = "v$TagName-NB"
|
||||||
$a.nightlybuild.published_at = $published_at
|
$a.nightlybuild.published_at = $published_at
|
||||||
$a.nightlybuild.html_url = $html_url
|
$a.nightlybuild.html_url = $html_url
|
||||||
$a.nightlybuild.assets.portable.browser_download_url = $browser_download_url
|
$a.nightlybuild.assets.portable.browser_download_url = $browser_download_url
|
||||||
$a.nightlybuild.assets.portable.checksum = $checksum
|
$a.nightlybuild.assets.portable.checksum = $checksum
|
||||||
$a.nightlybuild.assets.portable.size = $file_size
|
$a.nightlybuild.assets.portable.size = $file_size
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
"Preview" {
|
"Preview" {
|
||||||
$GithubTag = "$TagName-PB"
|
$GithubTag = "$TagName-PB"
|
||||||
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
||||||
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($zipFile.Name)"
|
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($zipFile.Name)"
|
||||||
$a.prerelease.name = "v$TagName-PB"
|
$a.prerelease.name = "v$TagName-PB"
|
||||||
$a.prerelease.published_at = $published_at
|
$a.prerelease.published_at = $published_at
|
||||||
$a.prerelease.html_url = $html_url
|
$a.prerelease.html_url = $html_url
|
||||||
$a.prerelease.assets.portable.browser_download_url = $browser_download_url
|
$a.prerelease.assets.portable.browser_download_url = $browser_download_url
|
||||||
$a.prerelease.assets.portable.checksum = $checksum
|
$a.prerelease.assets.portable.checksum = $checksum
|
||||||
$a.prerelease.assets.portable.size = $file_size
|
$a.prerelease.assets.portable.size = $file_size
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
"Stable" {
|
"Stable" {
|
||||||
$GithubTag = "$TagName"
|
$GithubTag = "$TagName"
|
||||||
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
$html_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/tag/$GithubTag"
|
||||||
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($zipFile.Name)"
|
$browser_download_url = "https://github.com/$WebsiteTargetOwner/$MainRepository/releases/download/$GithubTag/$($zipFile.Name)"
|
||||||
$a.stable.name = "v$TagName"
|
$a.stable.name = "v$TagName"
|
||||||
$a.stable.published_at = $published_at
|
$a.stable.published_at = $published_at
|
||||||
$a.stable.html_url = $html_url
|
$a.stable.html_url = $html_url
|
||||||
$a.stable.assets.portable.browser_download_url = $browser_download_url
|
$a.stable.assets.portable.browser_download_url = $browser_download_url
|
||||||
$a.stable.assets.portable.checksum = $checksum
|
$a.stable.assets.portable.checksum = $checksum
|
||||||
$a.stable.assets.portable.size = $file_size
|
$a.stable.assets.portable.size = $file_size
|
||||||
break
|
break
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
$a | ConvertTo-Json -Depth 10 | Set-Content $websiteJsonReleaseFile
|
$a | ConvertTo-Json -Depth 10 | Set-Content $websiteJsonReleaseFile
|
||||||
|
|
||||||
# commit releases.json change
|
# commit releases.json change
|
||||||
if ($env:WEBSITE_UPDATE_ENABLED.ToLower() -eq "true") {
|
if ($env:WEBSITE_UPDATE_ENABLED.ToLower() -eq "true") {
|
||||||
Write-Output "publish releases.json"
|
Write-Output "publish releases.json"
|
||||||
if (Test-Path -Path "$ReleaseFolder\releases.json") {
|
if (Test-Path -Path "$ReleaseFolder\releases.json") {
|
||||||
$releases_json_string = Get-Content "$ReleaseFolder\releases.json" | Out-String
|
$releases_json_string = Get-Content "$ReleaseFolder\releases.json" | Out-String
|
||||||
Set-GitHubContent -OwnerName $WebsiteTargetOwner -RepositoryName $WebsiteTargetRepository -Path _data\releases.json -CommitMessage "Updated for $UpdateChannel $ModifiedTagName" -Content $releases_json_string -BranchName main
|
Set-GitHubContent -OwnerName $WebsiteTargetOwner -RepositoryName $WebsiteTargetRepository -Path _data\releases.json -CommitMessage "Updated for $UpdateChannel $ModifiedTagName" -Content $releases_json_string -BranchName main
|
||||||
Write-Output "publish completed"
|
Write-Output "publish completed"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
Write-Output "ReleaseFolder not found"
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
Write-Output "ReleaseFolder not found"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -18,10 +18,11 @@ Write-Output "===== Begin $($PSCmdlet.MyInvocation.MyCommand) ====="
|
|||||||
$IsAppVeyor = !([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))
|
$IsAppVeyor = !([string]::IsNullOrEmpty($Env:APPVEYOR_BUILD_FOLDER))
|
||||||
|
|
||||||
$ConfigurationName = $ConfigurationName.Trim()
|
$ConfigurationName = $ConfigurationName.Trim()
|
||||||
Write-Output "Config Name (trimmed): '$($ConfigurationName)'"
|
|
||||||
$exe = Join-Path -Path $TargetDir -ChildPath $TargetFileName
|
$exe = Join-Path -Path $TargetDir -ChildPath $TargetFileName
|
||||||
$version = ((Get-Item -Path $exe).VersionInfo | Select-Object -Property ProductVersion)."ProductVersion"
|
#$version = ((Get-Item -Path $exe).VersionInfo | Select-Object -Property ProductVersion)."ProductVersion"
|
||||||
Write-Output "Version is $($version)"
|
$version = $(Get-Item -Path $exe).VersionInfo.FileVersion
|
||||||
|
Write-Output "FileVersion: $version"
|
||||||
|
|
||||||
|
|
||||||
# determine update channel
|
# determine update channel
|
||||||
if ($env:APPVEYOR_PROJECT_NAME -match "(Nightly)") {
|
if ($env:APPVEYOR_PROJECT_NAME -match "(Nightly)") {
|
||||||
@@ -44,57 +45,49 @@ if($IsAppVeyor) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
# Package debug symbols zip file
|
# Package debug symbols zip file
|
||||||
if ($ConfigurationName -match "Release") {
|
Write-Output "Packaging debug symbols"
|
||||||
|
$zipFilePrefix = "mRemoteNG-symbols"
|
||||||
Write-Output "Packaging debug symbols"
|
$pdbFiles = Get-ChildItem -Path $SolutionDir -Filter *.pdb -Recurse
|
||||||
|
$tempPdbPath = (New-TemporaryDirectory)[0]
|
||||||
if ($ConfigurationName -match "Portable") {
|
foreach ($pdbFile in $pdbFiles) {
|
||||||
$zipFilePrefix = "mRemoteNG-Portable-symbols"
|
if (($pdbFile.FullName).Contains("\$ConfigurationName\")) {
|
||||||
} else {
|
Copy-Item $pdbFile.FullName -Destination $tempPdbPath -Force
|
||||||
$zipFilePrefix = "mRemoteNG-Installer-symbols"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$debugFile = Join-Path -Path $TargetDir -ChildPath "mRemoteNG.pdb"
|
|
||||||
|
|
||||||
# AppVeyor build
|
|
||||||
if ($IsAppVeyor) {
|
|
||||||
$outputZipPath = Join-Path -Path $SolutionDir -ChildPath "Release\$zipFilePrefix-$($ModifiedVersion).zip"
|
|
||||||
7z a $outputZipPath $debugFile
|
|
||||||
}
|
|
||||||
# Local build
|
|
||||||
else {
|
|
||||||
if (!(Test-Path -Path $debugFile -PathType Leaf))
|
|
||||||
{
|
|
||||||
$outputZipPath = "$($SolutionDir)Release\$zipFilePrefix-$($ModifiedVersion).zip"
|
|
||||||
Compress-Archive $debugFile $outputZipPath -Force
|
|
||||||
} else {
|
|
||||||
Write-Output "File do not exist:" $debugFile", nothing to compress"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Remove-Item $debugFile
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($IsAppVeyor) {
|
||||||
|
# AppVeyor build
|
||||||
|
$outputZipPath = Join-Path -Path $SolutionDir -ChildPath "Release\$zipFilePrefix-$($ModifiedVersion).zip"
|
||||||
|
Write-Output "outputZipPath: $outputZipPath"
|
||||||
|
7z a $outputZipPath "$tempPdbPath\*.pdb"
|
||||||
|
}
|
||||||
|
# else {
|
||||||
|
# # Local build
|
||||||
|
# $outputZipPath = "$($SolutionDir)Release\$zipFilePrefix-$($ModifiedVersion).zip"
|
||||||
|
# Write-Output "outputZipPath: $outputZipPath"
|
||||||
|
# Compress-Archive -Path $tempPdbPath -DestinationPath $outputZipPath -Force
|
||||||
|
# }
|
||||||
|
|
||||||
|
|
||||||
# Package portable release zip file
|
# Package portable release zip file
|
||||||
if ($ConfigurationName -eq "Release Portable") {
|
Write-Output "Packaging portable ZIP file"
|
||||||
Write-Output "Packaging portable ZIP file"
|
# AppVeyor build
|
||||||
|
if ($IsAppVeyor) {
|
||||||
# AppVeyor build
|
$outputZipPath = Join-Path -Path $SolutionDir -ChildPath "Release\mRemoteNG-Portable-$($ModifiedVersion).zip"
|
||||||
if ($IsAppVeyor) {
|
7z a -bt -bd -bb1 -mx=9 -tzip -y -r $outputZipPath $TargetDir\*
|
||||||
$outputZipPath = Join-Path -Path $SolutionDir -ChildPath "Release\mRemoteNG-Portable-$($ModifiedVersion).zip"
|
Write-Output "Portable ZIP: $outputZipPath"
|
||||||
7z a -bt -bd -bb1 -mx=9 -tzip -y -r $outputZipPath $TargetDir\*
|
}
|
||||||
}
|
# Local build
|
||||||
# Local build
|
else {
|
||||||
else {
|
if ($Source)
|
||||||
if ($Source)
|
{
|
||||||
{
|
$outputZipPath="$($SolutionDir)\Release\mRemoteNG-Portable-$($ModifiedVersion).zip"
|
||||||
$outputZipPath="$($SolutionDir)\Release\mRemoteNG-Portable-$($ModifiedVersion).zip"
|
Compress-Archive $Source $outputZipPath -Force
|
||||||
Compress-Archive $Source $outputZipPath -Force
|
} else {
|
||||||
} else {
|
Write-Output "Files do not exist:" $Source", nothing to compress"
|
||||||
Write-Output "File do not exist:" $Source", nothing to compress"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
Write-Output "End $($PSCmdlet.MyInvocation.MyCommand)"
|
Write-Output "End $($PSCmdlet.MyInvocation.MyCommand)"
|
||||||
Write-Output ""
|
Write-Output ""
|
||||||
|
|||||||
@@ -27,8 +27,7 @@ Global
|
|||||||
Debug Installer|x64 = Debug Installer|x64
|
Debug Installer|x64 = Debug Installer|x64
|
||||||
Debug Portable|x64 = Debug Portable|x64
|
Debug Portable|x64 = Debug Portable|x64
|
||||||
Debug|x64 = Debug|x64
|
Debug|x64 = Debug|x64
|
||||||
Release Installer|x64 = Release Installer|x64
|
Release Installer and Portable|x64 = Release Installer and Portable|x64
|
||||||
Release Portable|x64 = Release Portable|x64
|
|
||||||
Release|x64 = Release|x64
|
Release|x64 = Release|x64
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||||
@@ -38,42 +37,34 @@ Global
|
|||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Debug Portable|x64.Build.0 = Debug Portable|x64
|
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Debug Portable|x64.Build.0 = Debug Portable|x64
|
||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Debug|x64.ActiveCfg = Debug|x64
|
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Debug|x64.Build.0 = Debug|x64
|
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Debug|x64.Build.0 = Debug|x64
|
||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release Installer|x64.ActiveCfg = Release|x64
|
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release Installer and Portable|x64.ActiveCfg = Release|x64
|
||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release Installer|x64.Build.0 = Release|x64
|
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release Installer and Portable|x64.Build.0 = Release|x64
|
||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release Portable|x64.ActiveCfg = Release Portable|x64
|
|
||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release Portable|x64.Build.0 = Release Portable|x64
|
|
||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release|x64.ActiveCfg = Release|x64
|
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release|x64.ActiveCfg = Release|x64
|
||||||
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release|x64.Build.0 = Release|x64
|
{4934A491-40BC-4E5B-9166-EA1169A220F6}.Release|x64.Build.0 = Release|x64
|
||||||
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Debug Installer|x64.ActiveCfg = Debug|x64
|
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Debug Installer|x64.ActiveCfg = Debug|x64
|
||||||
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Debug Portable|x64.ActiveCfg = Debug Portable|x64
|
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Debug Portable|x64.ActiveCfg = Debug Portable|x64
|
||||||
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Debug|x64.ActiveCfg = Debug|x64
|
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Release Installer|x64.ActiveCfg = Release|x64
|
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Debug|x64.Build.0 = Debug|x64
|
||||||
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Release Portable|x64.ActiveCfg = Release Portable|x64
|
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Release Installer and Portable|x64.ActiveCfg = Release|x64
|
||||||
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Release Portable|x64.Build.0 = Release Portable|x64
|
|
||||||
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Release|x64.ActiveCfg = Release|x64
|
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Release|x64.ActiveCfg = Release|x64
|
||||||
{1453B37F-8621-499E-B0B2-6091F76DC0BB}.Release|x64.Build.0 = Release|x64
|
|
||||||
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Debug Installer|x64.ActiveCfg = Debug|x64
|
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Debug Installer|x64.ActiveCfg = Debug|x64
|
||||||
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Debug Installer|x64.Build.0 = Debug|x64
|
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Debug Installer|x64.Build.0 = Debug|x64
|
||||||
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Debug Portable|x64.ActiveCfg = Debug Portable|x64
|
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Debug Portable|x64.ActiveCfg = Debug Portable|x64
|
||||||
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Debug|x64.ActiveCfg = Debug|x64
|
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Release Installer|x64.ActiveCfg = Release|x64
|
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Release Installer and Portable|x64.ActiveCfg = Release|x64
|
||||||
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Release Installer|x64.Build.0 = Release|x64
|
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Release Installer and Portable|x64.Build.0 = Release|x64
|
||||||
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Release Portable|x64.ActiveCfg = Release Portable|x64
|
|
||||||
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Release|x64.ActiveCfg = Release|x64
|
{5423D985-CB48-4344-B47F-E8C6D60C8B04}.Release|x64.ActiveCfg = Release|x64
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Debug Installer|x64.ActiveCfg = Debug|x64
|
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Debug Installer|x64.ActiveCfg = Debug|x64
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Debug Installer|x64.Build.0 = Debug|x64
|
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Debug Installer|x64.Build.0 = Debug|x64
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Debug Portable|x64.ActiveCfg = Debug Portable|x64
|
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Debug Portable|x64.ActiveCfg = Debug Portable|x64
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Debug|x64.ActiveCfg = Debug|x64
|
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Release Installer|x64.ActiveCfg = Release|x64
|
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Release Installer and Portable|x64.ActiveCfg = Release|x64
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Release Installer|x64.Build.0 = Release|x64
|
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Release Installer and Portable|x64.Build.0 = Release|x64
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Release Portable|x64.ActiveCfg = Release Portable|x64
|
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Release|x64.ActiveCfg = Release|x64
|
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Release|x64.ActiveCfg = Release|x64
|
||||||
{F0168B9F-6815-40DF-BA53-46CEE7683B68}.Release|x64.Build.0 = Release|x64
|
|
||||||
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Debug Installer|x64.ActiveCfg = Debug|x64
|
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Debug Installer|x64.ActiveCfg = Debug|x64
|
||||||
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Debug Portable|x64.ActiveCfg = Debug Portable|x64
|
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Debug Portable|x64.ActiveCfg = Debug Portable|x64
|
||||||
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Debug|x64.ActiveCfg = Debug|x64
|
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Release Installer|x64.ActiveCfg = Release|x64
|
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Release Installer and Portable|x64.ActiveCfg = Release|x64
|
||||||
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Release Portable|x64.ActiveCfg = Release Portable|x64
|
|
||||||
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Release|x64.ActiveCfg = Release|x64
|
{16AA21E2-D6B7-427D-AB7D-AA8C611B724E}.Release|x64.ActiveCfg = Release|x64
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug Installer|x64.ActiveCfg = Debug|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug Installer|x64.ActiveCfg = Debug|x64
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug Installer|x64.Build.0 = Debug|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug Installer|x64.Build.0 = Debug|x64
|
||||||
@@ -81,10 +72,8 @@ Global
|
|||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug Portable|x64.Build.0 = Debug Portable|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug Portable|x64.Build.0 = Debug Portable|x64
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug|x64.ActiveCfg = Debug|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug|x64.Build.0 = Debug|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Debug|x64.Build.0 = Debug|x64
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release Installer|x64.ActiveCfg = Release|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release Installer and Portable|x64.ActiveCfg = Release|x64
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release Installer|x64.Build.0 = Release|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release Installer and Portable|x64.Build.0 = Release|x64
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release Portable|x64.ActiveCfg = Release Portable|x64
|
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release Portable|x64.Build.0 = Release Portable|x64
|
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release|x64.ActiveCfg = Release|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release|x64.ActiveCfg = Release|x64
|
||||||
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release|x64.Build.0 = Release|x64
|
{A56A2029-79B8-492A-ABE5-D2BFE05801BD}.Release|x64.Build.0 = Release|x64
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
|
|||||||
@@ -23,6 +23,7 @@
|
|||||||
<RepositoryUrl>https://github.com/mRemoteNG/mRemoteNG.git</RepositoryUrl>
|
<RepositoryUrl>https://github.com/mRemoteNG/mRemoteNG.git</RepositoryUrl>
|
||||||
<RepositoryType>git</RepositoryType>
|
<RepositoryType>git</RepositoryType>
|
||||||
<StartupObject>mRemoteNG.App.ProgramRoot</StartupObject>
|
<StartupObject>mRemoteNG.App.ProgramRoot</StartupObject>
|
||||||
|
<ProduceReferenceAssembly>True</ProduceReferenceAssembly>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||||
<DefineConstants>DEBUG</DefineConstants>
|
<DefineConstants>DEBUG</DefineConstants>
|
||||||
@@ -41,7 +42,7 @@
|
|||||||
<WarningsAsErrors />
|
<WarningsAsErrors />
|
||||||
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
|
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
|
||||||
<WarningLevel>7</WarningLevel>
|
<WarningLevel>7</WarningLevel>
|
||||||
<ResolveComReferenceSilent>False</ResolveComReferenceSilent>
|
<ResolveComReferenceSilent>True</ResolveComReferenceSilent>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Portable|x64'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Portable|x64'">
|
||||||
<DefineConstants>DEBUG;PORTABLE</DefineConstants>
|
<DefineConstants>DEBUG;PORTABLE</DefineConstants>
|
||||||
@@ -60,13 +61,13 @@
|
|||||||
<WarningsAsErrors />
|
<WarningsAsErrors />
|
||||||
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
|
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
|
||||||
<WarningLevel>7</WarningLevel>
|
<WarningLevel>7</WarningLevel>
|
||||||
<ResolveComReferenceSilent>False</ResolveComReferenceSilent>
|
<ResolveComReferenceSilent>True</ResolveComReferenceSilent>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Installer|x64'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Installer|x64'">
|
||||||
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
|
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
|
||||||
<Optimize>True</Optimize>
|
<Optimize>True</Optimize>
|
||||||
<WarningLevel>7</WarningLevel>
|
<WarningLevel>7</WarningLevel>
|
||||||
<ResolveComReferenceSilent>False</ResolveComReferenceSilent>
|
<ResolveComReferenceSilent>True</ResolveComReferenceSilent>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Remove="buildenv.tmp" />
|
<None Remove="buildenv.tmp" />
|
||||||
@@ -486,7 +487,7 @@
|
|||||||
<Exec Command="echo $(ConfigurationName) > buildenv.tmp
powershell.exe -WindowStyle Hidden -NonInteractive -ExecutionPolicy Bypass -Command "& { $Env:DevEnvDir = ($(SolutionDir)Tools/find_vstool.ps1 devenv.exe); $Env:DevEnvDir = ($Env:DevEnvDir.Replace('devenv.exe','')).replace('`',''); $Env:DevEnvDir; if ($Env:APPVEYOR) {&'$(DevEnvDir)TextTransform.exe' -a !!BuildConfiguration!'$(Configuration)' '$(ProjectDir)Properties\AssemblyInfo.tt'} }"" />
|
<Exec Command="echo $(ConfigurationName) > buildenv.tmp
powershell.exe -WindowStyle Hidden -NonInteractive -ExecutionPolicy Bypass -Command "& { $Env:DevEnvDir = ($(SolutionDir)Tools/find_vstool.ps1 devenv.exe); $Env:DevEnvDir = ($Env:DevEnvDir.Replace('devenv.exe','')).replace('`',''); $Env:DevEnvDir; if ($Env:APPVEYOR) {&'$(DevEnvDir)TextTransform.exe' -a !!BuildConfiguration!'$(Configuration)' '$(ProjectDir)Properties\AssemblyInfo.tt'} }"" />
|
||||||
</Target>
|
</Target>
|
||||||
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
|
<Target Name="PostBuild" AfterTargets="PostBuildEvent">
|
||||||
<Exec Command=":: When passing paths to powershell scripts, check if the path ends with a backslash "\"
:: If it does, then the backslash may be interpreted as an escape character. Add another backslash to cancel the first one.

powershell -noprofile -command "sleep 2"

set /p buildenv=<buildenv.tmp

:: Manual builds, set the cert password and uncomment below.
:: IF "%25APPVEYOR_BUILD_FOLDER"=="" ( set cert_pwd= )

:: Call the post build powershell script
powershell.exe -ExecutionPolicy Bypass -File "$(SolutionDir)Tools\postbuild_portable.ps1" -SolutionDir "$(SolutionDir)\" -TargetDir "$(TargetDir)\" -TargetFileName "mRemoteNG.exe" -ConfigurationName "%25buildenv%25" -CertificatePath "$(CertPath)" -CertificatePassword "$(CertPassword)" -ExcludeFromSigning "PuTTYNG.exe"" />
|
<Exec Command=":: When passing paths to powershell scripts, check if the path ends with a backslash "\"
:: If it does, then the backslash may be interpreted as an escape character. Add another backslash to cancel the first one.

powershell -noprofile -command "sleep 2"

set /p buildenv=<buildenv.tmp

:: Manual builds, set the cert password and uncomment below.
:: IF "%25APPVEYOR_BUILD_FOLDER"=="" ( set cert_pwd= )

:: Call the post build powershell script
powershell.exe -ExecutionPolicy Bypass -File "$(SolutionDir)Tools\postbuild.ps1" -SolutionDir "$(SolutionDir)\" -TargetDir "$(TargetDir)\" -TargetFileName "mRemoteNG.exe" -ConfigurationName "%25buildenv%25" -CertificatePath "$(CertPath)" -CertificatePassword "$(CertPassword)" -ExcludeFromSigning "PuTTYNG.exe"" />
|
||||||
</Target>
|
</Target>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\ExternalConnectors\ExternalConnectors.csproj" />
|
<ProjectReference Include="..\ExternalConnectors\ExternalConnectors.csproj" />
|
||||||
|
|||||||
@@ -115,6 +115,9 @@
|
|||||||
<File Id="filAC4D49028FDDA1626E5B006C9D1ED57E" KeyPath="yes" Source="$(var.HarvestPath)\mRemoteNG.dll.config" />
|
<File Id="filAC4D49028FDDA1626E5B006C9D1ED57E" KeyPath="yes" Source="$(var.HarvestPath)\mRemoteNG.dll.config" />
|
||||||
</Component>
|
</Component>
|
||||||
|
|
||||||
|
<Component Id="cmp67313C6B4CE3487E9A8165EFFE369D16" Directory="INSTALLDIR" Guid="*">
|
||||||
|
<File Id="fil5F0524AF62166FF3C4DAE07F1113C0D9" KeyPath="yes" Source="$(var.HarvestPath)\mRemoteNG.pdb" />
|
||||||
|
</Component>
|
||||||
<Component Id="cmp9FF194CCD09E9797444CF95F7C37C75A" Directory="INSTALLDIR" Guid="*">
|
<Component Id="cmp9FF194CCD09E9797444CF95F7C37C75A" Directory="INSTALLDIR" Guid="*">
|
||||||
<File Id="fil09655B2FCDF14CBBA2E03BBD3F6C58EE" KeyPath="yes" Source="$(var.HarvestPath)\mRemoteNG.runtimeconfig.json" />
|
<File Id="fil09655B2FCDF14CBBA2E03BBD3F6C58EE" KeyPath="yes" Source="$(var.HarvestPath)\mRemoteNG.runtimeconfig.json" />
|
||||||
</Component>
|
</Component>
|
||||||
@@ -420,6 +423,9 @@
|
|||||||
<Component Id="cmp94B0CA4E5F2F6D28611A655BDB449E1E" Directory="dir54B0732D1EC7055747BB11A9069B5872" Guid="*">
|
<Component Id="cmp94B0CA4E5F2F6D28611A655BDB449E1E" Directory="dir54B0732D1EC7055747BB11A9069B5872" Guid="*">
|
||||||
<File Id="filDD3B91C7B1FF8E22F8E658E542840D55" KeyPath="yes" Source="$(var.HarvestPath)\Schemas\mremoteng_confcons_v2_7.xsd" />
|
<File Id="filDD3B91C7B1FF8E22F8E658E542840D55" KeyPath="yes" Source="$(var.HarvestPath)\Schemas\mremoteng_confcons_v2_7.xsd" />
|
||||||
</Component>
|
</Component>
|
||||||
|
<Component Id="cmp33BB9F0091C56A034105A47C3035D1A9" Directory="dir54B0732D1EC7055747BB11A9069B5872" Guid="*">
|
||||||
|
<File Id="fil518DA4E8D2E5F7E1FEF6055DD9BB727E" KeyPath="yes" Source="$(var.HarvestPath)\Schemas\mremoteng_confcons_v2_8.xsd" />
|
||||||
|
</Component>
|
||||||
<Component Id="cmpB902A64979524E0126DB594BA240DEB7" Directory="dir54B0732D1EC7055747BB11A9069B5872" Guid="*">
|
<Component Id="cmpB902A64979524E0126DB594BA240DEB7" Directory="dir54B0732D1EC7055747BB11A9069B5872" Guid="*">
|
||||||
<File Id="filED09F28F7EEE2FFFB9BF6657D70C9D98" KeyPath="yes" Source="$(var.HarvestPath)\Schemas\mremoteng_credrepo_list_v1_0.xsd" />
|
<File Id="filED09F28F7EEE2FFFB9BF6657D70C9D98" KeyPath="yes" Source="$(var.HarvestPath)\Schemas\mremoteng_credrepo_list_v1_0.xsd" />
|
||||||
</Component>
|
</Component>
|
||||||
|
|||||||
Reference in New Issue
Block a user