File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,6 +9,10 @@ permissions:
99on :
1010 workflow_call :
1111 inputs :
12+ ref :
13+ description : ' Git ref to checkout (commit SHA or tag)'
14+ required : true
15+ type : string
1216 upload-artifacts :
1317 description : ' Whether to upload artifacts'
1418 required : false
7478 steps :
7579 - name : Checkout code
7680 uses : actions/checkout@v4
81+ with :
82+ ref : ${{ inputs.ref }}
7783
7884 - name : Setup Rust
7985 uses : dtolnay/rust-toolchain@stable
Original file line number Diff line number Diff line change @@ -9,6 +9,10 @@ permissions:
99on :
1010 workflow_call :
1111 inputs :
12+ ref :
13+ description : ' Git ref to checkout (commit SHA or tag)'
14+ required : true
15+ type : string
1216 version :
1317 description : ' Version string for package naming (optional, reads from Cargo.toml if not provided)'
1418 required : false
4751 steps :
4852 - name : Checkout code
4953 uses : actions/checkout@v4
54+ with :
55+ ref : ${{ inputs.ref }}
5056
5157 - name : Setup Rust
5258 uses : dtolnay/rust-toolchain@stable
@@ -193,6 +199,8 @@ jobs:
193199 steps :
194200 - name : Checkout code
195201 uses : actions/checkout@v4
202+ with :
203+ ref : ${{ inputs.ref }}
196204
197205 - name : Setup Rust
198206 uses : dtolnay/rust-toolchain@stable
@@ -266,6 +274,8 @@ jobs:
266274 steps :
267275 - name : Checkout code
268276 uses : actions/checkout@v4
277+ with :
278+ ref : ${{ inputs.ref }}
269279
270280 - name : Setup Rust
271281 uses : dtolnay/rust-toolchain@stable
Original file line number Diff line number Diff line change @@ -124,6 +124,7 @@ jobs:
124124 needs : [test, cargo-make]
125125 uses : ./.github/workflows/_build-binaries.yml
126126 with :
127+ ref : ${{ github.sha }}
127128 upload-artifacts : true
128129 artifact-retention-days : 7
129130
@@ -135,6 +136,7 @@ jobs:
135136 needs : [test, cargo-make]
136137 uses : ./.github/workflows/_build-packages.yml
137138 with :
139+ ref : ${{ github.sha }}
138140 artifact-retention-days : 7
139141
140142 # ============================================
Original file line number Diff line number Diff line change 7474 if : needs.semantic-release.outputs.new_release_published == 'true'
7575 uses : ./.github/workflows/_build-binaries.yml
7676 with :
77+ ref : v${{ needs.semantic-release.outputs.new_release_version }}
7778 upload-artifacts : true
7879 artifact-retention-days : 1
7980
8687 if : needs.semantic-release.outputs.new_release_published == 'true'
8788 uses : ./.github/workflows/_build-packages.yml
8889 with :
90+ ref : v${{ needs.semantic-release.outputs.new_release_version }}
8991 version : ${{ needs.semantic-release.outputs.new_release_version }}
9092 artifact-retention-days : 1
9193
Original file line number Diff line number Diff line change @@ -7,5 +7,14 @@ if [ -f .git/MERGE_HEAD ]; then
77 exit 0
88fi
99
10- # Run QA checks for regular commits
10+ # Check if any Rust files are staged for commit
11+ RUST_FILES=$( git diff --cached --name-only --diff-filter=ACMR | grep -E ' \.(rs)$|^Cargo\.(toml|lock)$' || true)
12+
13+ if [ -z " $RUST_FILES " ]; then
14+ echo " No Rust files changed, skipping cargo make qa"
15+ exit 0
16+ fi
17+
18+ # Run QA checks for commits with Rust changes
19+ echo " Rust files changed, running cargo make qa..."
1120cargo make qa
You can’t perform that action at this time.
0 commit comments