Skip to content

Commit 2f6a447

Browse files
committed
Include Linux binaries in release workflow & bump version
Also use the scheduler binary for Linux in the release workflow to query the version. CMK-18620
1 parent 79ca361 commit 2f6a447

File tree

4 files changed

+38
-15
lines changed

4 files changed

+38
-15
lines changed

.github/workflows/release.yaml

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,6 @@ jobs:
1818
steps:
1919
- uses: actions/checkout@v4
2020

21-
- uses: actions-rust-lang/[email protected]
22-
with:
23-
target: x86_64-unknown-linux-gnu
24-
# By default, setup-rust-toolchain sets "-D warnings". As a side effect, the settings in
25-
# .cargo/config.toml are ignored:
26-
# https://doc.rust-lang.org/cargo/reference/config.html#buildrustflags
27-
# "There are four mutually exclusive sources of extra flags"
28-
rustflags: ""
29-
3021
- uses: actions/download-artifact@v4
3122
with:
3223
name: rcc
@@ -37,12 +28,20 @@ jobs:
3728
name: rmk_windows64
3829
path: artifact/rmk_windows64/
3930

31+
- uses: actions/download-artifact@v4
32+
with:
33+
name: rmk_linux64
34+
path: artifact/rmk_linux64/
35+
4036
- run: zip -r executables.zip artifact
4137

4238
- name: "Compute release tag"
4339
id: compute-tag
4440
run: |
45-
version="$(cargo run --bin robotmk_scheduler -- --version | cut --delimiter " " --fields 2)"
41+
# file permissions are not retained during upload:
42+
# https://github.com/actions/upload-artifact?tab=readme-ov-file#permission-loss
43+
chmod +x artifact/rmk_linux64/robotmk_scheduler
44+
version="$(./artifact/rmk_linux64/robotmk_scheduler --version | cut --delimiter " " --fields 2)"
4645
echo "TAG=v${version}" >> "${GITHUB_OUTPUT}"
4746
4847
- name: "Push release tag"

.github/workflows/robotmk_build.yaml

Lines changed: 27 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ name: "Build Robotmk"
44
on:
55
workflow_call: {}
66
jobs:
7-
build_robotmk:
7+
build_windows:
88
runs-on: windows-latest
99
steps:
1010
- uses: actions/checkout@v4
@@ -24,6 +24,30 @@ jobs:
2424
with:
2525
name: rmk_windows64
2626
path: |
27-
${{ github.workspace }}/target/x86_64-pc-windows-gnu/release/robotmk_scheduler.exe
28-
${{ github.workspace }}/target/x86_64-pc-windows-gnu/release/robotmk_agent_plugin.exe
27+
target/x86_64-pc-windows-gnu/release/robotmk_scheduler.exe
28+
target/x86_64-pc-windows-gnu/release/robotmk_agent_plugin.exe
29+
if-no-files-found: error
30+
31+
build_linux:
32+
runs-on: ubuntu-latest
33+
steps:
34+
- uses: actions/checkout@v4
35+
36+
- uses: actions-rust-lang/[email protected]
37+
with:
38+
target: x86_64-unknown-linux-gnu
39+
# By default, setup-rust-toolchain sets "-D warnings". As a side effect, the settings in
40+
# .cargo/config.toml are ignored:
41+
# https://doc.rust-lang.org/cargo/reference/config.html#buildrustflags
42+
# "There are four mutually exclusive sources of extra flags"
43+
rustflags: ""
44+
45+
- run: cargo build --target=x86_64-unknown-linux-gnu --release
46+
47+
- uses: actions/upload-artifact@v4
48+
with:
49+
name: rmk_linux64
50+
path: |
51+
target/x86_64-unknown-linux-gnu/release/robotmk_scheduler
52+
target/x86_64-unknown-linux-gnu/release/robotmk_agent_plugin
2953
if-no-files-found: error

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "robotmk"
3-
version = "3.0.0-alpha-4"
3+
version = "3.0.0-alpha-5"
44
edition = "2021"
55

66
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

0 commit comments

Comments
 (0)