Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/apt-arm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- master
- fluent-package-v5
- fluent-package-v6
pull_request:
concurrency:
group: ${{ github.head_ref || github.sha }}-${{ github.workflow }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/apt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- master
- fluent-package-v5
- fluent-package-v6
pull_request:
concurrency:
group: ${{ github.head_ref || github.sha }}-${{ github.workflow }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/bundle-audit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- master
- fluent-package-v5
- fluent-package-v6
pull_request:
workflow_dispatch:
concurrency:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- master
- fluent-package-v5
- fluent-package-v6
pull_request:
concurrency:
group: ${{ github.head_ref || github.sha }}-${{ github.workflow }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- master
- fluent-package-v5
- fluent-package-v6
pull_request:
concurrency:
group: ${{ github.head_ref || github.sha }}-${{ github.workflow }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/yum-arm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- master
- fluent-package-v5
- fluent-package-v6
pull_request:
concurrency:
group: ${{ github.head_ref || github.sha }}-${{ github.workflow }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/yum.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
branches:
- master
- fluent-package-v5
- fluent-package-v6
pull_request:
concurrency:
group: ${{ github.head_ref || github.sha }}-${{ github.workflow }}
Expand Down
17 changes: 11 additions & 6 deletions fluent-package/msi/pkgsize-test.ps1
Original file line number Diff line number Diff line change
@@ -1,22 +1,27 @@
$ErrorActionPreference = 'Stop'

$PSVersionTable

$base_uri = "http://packages.treasuredata.com.s3.amazonaws.com"
&git fetch --unshallow
$previous_version = (git describe --abbrev=0 --tags) -Replace "v",""
$major_version = ([version] $previous_version).Major
try {
$previous_version = (git describe --abbrev=0 --tags) -Replace "v",""
"Previous version from git: {0}" -F $previous_version | Write-Host
$previous_msi_name = "td-agent-${previous_version}-x64.msi"
$response = Invoke-WebRequest -Uri "${base_uri}/4/windows/${previous_msi_name}" -OutFile $previous_msi_name -PassThru
$previous_msi_name = "fluent-package-${previous_version}-x64.msi"
$response = Invoke-WebRequest -UseBasicParsing -Uri "${base_uri}/${major_version}/windows/${previous_msi_name}" -OutFile $previous_msi_name -PassThru
}
catch {
$heroku_uri = 'http://td-agent-package-browser.herokuapp.com'
Write-Host "An exception was caught: $($_.Exception.Message). Try to find previous version in ${heroku_uri} instead"
$msi_links = (Invoke-WebRequest -Uri "${heroku_uri}/4/windows").Links.href | Where-Object {$_ -like "*.msi"}
"Checking package major version: {0}" -F $major_version | Write-Host
"Checking {0}/{1}/windows" -F $heroku_uri, $major_version | Write-Host
$msi_links = (Invoke-WebRequest -UseBasicParsing -Uri "${heroku_uri}/${major_version}/windows").Links.href | Where-Object {$_ -like "*.msi"}
$msi_versions = $($msi_links | Select-String '(\d+\.\d+\.\d+)' | ForEach-Object { $_.Matches[0].Groups[1].Value }) | Sort-Object {[version] $_}
$previous_version = $msi_versions | Select-Object -Last 1
"Previous version from {0}: {1}" -F ${heroku_uri}, $previous_version | Write-Host
$previous_msi_name = "td-agent-${previous_version}-x64.msi"
$response = Invoke-WebRequest -Uri "${base_uri}/4/windows/${previous_msi_name}" -OutFile $previous_msi_name -PassThru
$previous_msi_name = "fluent-package-${previous_version}-x64.msi"
$response = Invoke-WebRequest -UseBasicParsing -Uri "${base_uri}/${major_version}/windows/${previous_msi_name}" -OutFile $previous_msi_name -PassThru
}

$msi = (Get-Item "fluent-package\\msi\\repositories\\fluent-package-*.msi") | Sort-Object -Descending { $_.LastWriteTime } | Select-Object -First 1
Expand Down
Loading