Skip to content

Commit 36f1820

Browse files
committed
chore: move windows publication to windows node
1 parent 5b530ed commit 36f1820

File tree

2 files changed

+43
-3
lines changed

2 files changed

+43
-3
lines changed

.github/workflows/publish.yml

Lines changed: 43 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ jobs:
7373
needs: nativeCompile
7474
name: "Create a new release"
7575
runs-on: ubuntu-latest
76+
outputs:
77+
RELEASE_VERSION: ${{ steps.get_version.outputs.VERSION }}
7678
env:
7779
SEGMENT_DOWNLOAD_TIMEOUT_MINS: "15"
7880
steps:
@@ -106,12 +108,52 @@ jobs:
106108
JRELEASER_PROJECT_VERSION: ${{ steps.get_version.outputs.VERSION }}
107109
JRELEASER_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
108110
JRELEASER_HOMEBREW_GITHUB_TOKEN: ${{ secrets.BREW_CHOCO_CLI_GH_TOKEN }}
111+
JRELEASER_DISTRIBUTIONS_SPOTLESS_CLI_BREW_ACTIVE: ALWAYS
112+
- name: "Persist jreleaser output"
113+
if: always()
114+
uses: actions/upload-artifact@v4
115+
with:
116+
name: jreleaser-release-unix
117+
path: |
118+
out/jreleaser/trace.log
119+
out/jreleaser/output.properties
120+
createChocoRelase:
121+
needs: createRelease
122+
name: "Publish chocolatey package"
123+
runs-on: windows-latest
124+
env:
125+
SEGMENT_DOWNLOAD_TIMEOUT_MINS: "15"
126+
steps:
127+
- name: "Checkout"
128+
uses: actions/checkout@v4
129+
with:
130+
fetch-depth: 0
131+
- name: "Install JDK 21"
132+
uses: "actions/setup-java@v4"
133+
with:
134+
distribution: "graalvm"
135+
java-version: 21
136+
- name: "Retrieve production-binaries"
137+
uses: "actions/download-artifact@v4"
138+
with:
139+
# no name - download all artifacts
140+
path: "app/build/collected-binaries"
141+
- name: "Publish distributions"
142+
uses: jreleaser/release-action@v2
143+
with:
144+
setup-java: false
145+
arguments: "publish"
146+
env:
147+
JRELEASER_PROJECT_VERSION: ${{ jobs.createRelease.outputs.RELEASE_VERSION }}
148+
JRELEASER_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
109149
JRELEASER_CHOCOLATEY_GITHUB_TOKEN: ${{ secrets.BREW_CHOCO_CLI_GH_TOKEN }}
150+
JRELEASER_CHOCOLATEY_API_KEY: ${{ secrets.CHOCO_API_KEY }}
151+
JRELEASER_DISTRIBUTIONS_SPOTLESS_CLI_CHOCOLATEY_ACTIVE: ALWAYS
110152
- name: "Persist jreleaser output"
111153
if: always()
112154
uses: actions/upload-artifact@v4
113155
with:
114-
name: jreleaser-release
156+
name: jreleaser-release-windows
115157
path: |
116158
out/jreleaser/trace.log
117159
out/jreleaser/output.properties

jreleaser.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,8 @@ distributions:
3838
platform: windows-x86_64
3939

4040
brew:
41-
active: RELEASE
4241
templateDirectory: app/src/jreleaser/distributions/spotless-cli/brew
4342
multiPlatform: true
4443

4544
chocolatey:
46-
active: RELEASE
4745
templateDirectory: app/src/jreleaser/distributions/spotless-cli/chocolatey

0 commit comments

Comments
 (0)