mirror of
https://github.com/transmission/transmission
synced 2025-01-03 13:35:36 +00:00
Don't pack PDBs on feature branches to reduce AppVeyor artifacts size (#1972)
This commit is contained in:
parent
290f7fc71a
commit
08996ab4c7
3 changed files with 12 additions and 5 deletions
|
@ -62,7 +62,8 @@ for:
|
||||||
try {
|
try {
|
||||||
& (Join-Path $Env:APPVEYOR_BUILD_FOLDER release windows main.ps1) `
|
& (Join-Path $Env:APPVEYOR_BUILD_FOLDER release windows main.ps1) `
|
||||||
-Mode Build `
|
-Mode Build `
|
||||||
-BuildArch $env:TR_ARCH
|
-BuildArch $env:TR_ARCH `
|
||||||
|
-NoPackDebugSyms:$($Env:APPVEYOR_REPO_BRANCH -match "/")
|
||||||
} catch {
|
} catch {
|
||||||
Write-Error ("{1}{0}{2}{0}{3}" -f [Environment]::NewLine, $_.ToString(), $_.InvocationInfo.PositionMessage, $_.ScriptStackTrace) -ErrorAction Continue
|
Write-Error ("{1}{0}{2}{0}{3}" -f [Environment]::NewLine, $_.ToString(), $_.InvocationInfo.PositionMessage, $_.ScriptStackTrace) -ErrorAction Continue
|
||||||
exit 1
|
exit 1
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/usr/bin/env pwsh
|
#!/usr/bin/env pwsh
|
||||||
|
|
||||||
function global:Build-Transmission([string] $PrefixDir, [string] $Arch, [string] $DepsPrefixDir, [string] $SourceDir, [string] $ArtifactsDir) {
|
function global:Build-Transmission([string] $PrefixDir, [string] $Arch, [string] $DepsPrefixDir, [string] $SourceDir, [string] $ArtifactsDir, [boolean] $NoPackDebugSyms) {
|
||||||
$BuildDir = Join-Path $SourceDir .build
|
$BuildDir = Join-Path $SourceDir .build
|
||||||
|
|
||||||
$env:PATH = @(
|
$env:PATH = @(
|
||||||
|
@ -64,7 +64,10 @@ function global:Build-Transmission([string] $PrefixDir, [string] $Arch, [string]
|
||||||
New-Item -Path $ArtifactsDir -ItemType Directory -ErrorAction Ignore | Out-Null
|
New-Item -Path $ArtifactsDir -ItemType Directory -ErrorAction Ignore | Out-Null
|
||||||
$MsiPackage = (Get-ChildItem (Join-Path $BuildDir dist msi 'transmission-*.msi'))[0]
|
$MsiPackage = (Get-ChildItem (Join-Path $BuildDir dist msi 'transmission-*.msi'))[0]
|
||||||
Move-Item -Path $MsiPackage.FullName -Destination $ArtifactsDir
|
Move-Item -Path $MsiPackage.FullName -Destination $ArtifactsDir
|
||||||
Invoke-NativeCommand cmake -E chdir $DebugSymbolsDir 7z a -y (Join-Path $ArtifactsDir "$($MsiPackage.BaseName)-pdb.7z")
|
|
||||||
|
if (-not $NoPackDebugSyms) {
|
||||||
|
Invoke-NativeCommand cmake -E chdir $DebugSymbolsDir 7z a -y (Join-Path $ArtifactsDir "$($MsiPackage.BaseName)-pdb.7z")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function global:Test-Transmission([string] $DepsPrefixDir, [string] $SourceDir) {
|
function global:Test-Transmission([string] $DepsPrefixDir, [string] $SourceDir) {
|
||||||
|
|
|
@ -16,7 +16,10 @@ Param(
|
||||||
[string] $RootDir,
|
[string] $RootDir,
|
||||||
|
|
||||||
[Parameter()]
|
[Parameter()]
|
||||||
[string] $ScriptBaseUrl
|
[string] $ScriptBaseUrl,
|
||||||
|
|
||||||
|
[Parameter()]
|
||||||
|
[switch] $NoPackDebugSyms
|
||||||
)
|
)
|
||||||
|
|
||||||
Set-StrictMode -Version '6.0'
|
Set-StrictMode -Version '6.0'
|
||||||
|
@ -247,7 +250,7 @@ if ($Mode -eq 'Build') {
|
||||||
Invoke-Build Curl
|
Invoke-Build Curl
|
||||||
Invoke-Build Qt
|
Invoke-Build Qt
|
||||||
|
|
||||||
Invoke-Build Transmission -NoCache -MoreArguments @($SourceDir, $SourceDir)
|
Invoke-Build Transmission -NoCache -MoreArguments @($SourceDir, $SourceDir, $NoPackDebugSyms.IsPresent)
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($Mode -eq 'Test') {
|
if ($Mode -eq 'Test') {
|
||||||
|
|
Loading…
Reference in a new issue