File tree 1 file changed +21
-8
lines changed
1 file changed +21
-8
lines changed Original file line number Diff line number Diff line change 12
12
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_LINKER : aarch64-linux-gnu-gcc
13
13
14
14
jobs :
15
+ # windows does not run git cliff so we need to do it here
16
+ extract_version :
17
+ name : Extract Version
18
+ runs-on : ubuntu-latest
19
+ outputs :
20
+ version : ${{ steps.set_version.outputs.version }}
21
+
22
+ steps :
23
+ - uses : actions/checkout@v4
24
+ with :
25
+ fetch-depth : 0
26
+
27
+ - name : Set up git-cliff
28
+ uses : kenji-miyake/setup-git-cliff@v1
29
+
30
+ - name : Set version name
31
+ id : set_version
32
+ run : echo "version=$(git cliff --bumped-version)" >> "$GITHUB_OUTPUT"
33
+
15
34
build_and_test :
16
35
name : Build & Test for ${{ matrix.config.target }}
36
+ needs : extract_version
17
37
strategy :
18
38
matrix :
19
39
config :
@@ -57,20 +77,13 @@ jobs:
57
77
env :
58
78
DATABASE_URL : postgres://postgres:postgres@localhost:5432/postgres
59
79
60
- - name : Set up git-cliff
61
- uses : kenji-miyake/setup-git-cliff@v1
62
-
63
- - name : Set version name
64
- run : echo "version=$(git cliff --bumped-version)" >> "$GITHUB_ENV"
65
-
66
80
- name : 🛠️ Run Build
67
81
run : cargo build -p pgt_cli --release --target ${{ matrix.config.target }}
68
82
env :
69
83
# Strip all debug symbols from the resulting binaries
70
84
RUSTFLAGS : " -C strip=symbols -C codegen-units=1"
71
85
# Inline the version in the CLI binary
72
- PGT_VERSION : ${{ env.version }}
73
-
86
+ PGT_VERSION : ${{ needs.extract_version.outputs.version }}
74
87
75
88
# windows is a special snowflake too, it saves binaries as .exe
76
89
- name : 👦 Name the Binary
You can’t perform that action at this time.
0 commit comments