Skip to content

Commit 2ba7cfa

Browse files
committed
Update the release PR message
1 parent 2a046d4 commit 2ba7cfa

File tree

6 files changed

+35
-15
lines changed

6 files changed

+35
-15
lines changed

.github/workflows/test.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@ name: "🧑‍🔬 Build and Test"
22

33
on:
44
workflow_dispatch:
5+
inputs:
6+
force-rebuild:
7+
required: false
8+
default: false
9+
type: boolean
10+
description: "Re-build Rust binaries"
511
push:
612
branches:
713
- 'run-on-ci/**'
@@ -21,6 +27,7 @@ jobs:
2127
binaries-path: ${{ env.BINARIES_PATH }}
2228
cache-key: ${{ env.CACHE_KEY }}
2329
cache-restore-key: ${{ env.CACHE_RESTORE_KEY }}
30+
force-rebuild: ${{ inputs.force-rebuild }}
2431

2532
steps:
2633
- run: echo "Just a hacky workaround for passing envs to jobs expecting them... ¯\_(ツ)_/¯"
@@ -34,6 +41,7 @@ jobs:
3441
binaries-path: ${{ needs.sharedInputs.outputs.binaries-path }}
3542
cache-key: ${{ needs.sharedInputs.outputs.cache-key }}
3643
cache-restore-key: ${{ needs.sharedInputs.outputs.cache-restore-key }}
44+
force-rebuild: "${{ needs.sharedInputs.outputs.force-rebuild }}"
3745

3846
testMacOS14:
3947
name: "🤖 Unit tests"

.github/workflows/tmpl_build_rust_binaries.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ on:
1515
cache-restore-key:
1616
required: true
1717
type: string
18+
force-rebuild:
19+
required: true
20+
type: string
1821

1922
jobs:
2023
buildRustBinaries:
@@ -44,17 +47,18 @@ jobs:
4447
restore-keys: |
4548
${{ inputs.cache-restore-key }}-${{ runner.os }}
4649
47-
- name: "🔍 Check binaries in ${{ inputs.binaries-path }}"
50+
- name: "🔍 Check binaries exist in ${{ inputs.binaries-path }}"
4851
id: check_files
4952
uses: andstor/file-existence-action@v3
5053
with:
5154
files: "Resources/**/libpact_ffi.a"
5255

5356
- name: "🛠 Prepare Tools"
57+
if: ${{ steps.check_files.outputs.files_exists == 'false' || inputs.force-rebuild == 'true' }}
5458
run: |
55-
sh Support/Scripts/prepare_build_tools
59+
sh Support/Scripts/Config/prepare_build_tools
5660
5761
- name: "🎁 Build FFI binaries (skipping if cached)"
58-
if: steps.check_files.outputs.files_exists == 'false'
62+
if: ${{ steps.check_files.outputs.files_exists == 'false' || inputs.force-rebuild == 'true' }}
5963
run: |
60-
sh Support/Scripts/build_rust_dependencies
64+
sh Support/Scripts/CI/build_rust_dependencies

.github/workflows/tmpl_test_macos13_x86_64.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "On macOS 13 (intel)"
1+
name: "macOS 13"
22

33
on:
44
workflow_call:
@@ -15,6 +15,7 @@ on:
1515
cache-restore-key:
1616
required: true
1717
type: string
18+
1819
env:
1920
DEVELOPER_DIR: /Applications/Xcode_15.4.app/Contents/Developer
2021

@@ -30,7 +31,7 @@ jobs:
3031
- scheme: "PactSwiftMockServer-iOS"
3132
destination: "platform=iOS Simulator,name=iPhone 14 Pro"
3233
- scheme: "PactSwiftMockServer-macOS"
33-
destination: "arch=x86_64"
34+
destination: "platform=macOS,arch=x86_64"
3435

3536
env:
3637
SCHEME: ${{ matrix.scheme }}

.github/workflows/tmpl_test_macos14_arm64.yml

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "On macOS 14 (latest)"
1+
name: "macOS 14"
22

33
on:
44
workflow_call:
@@ -24,12 +24,12 @@ on:
2424
workflow_dispatch:
2525

2626
env:
27-
DEVELOPER_DIR: /Applications/Xcode_15.3.app/Contents/Developer
27+
DEVELOPER_DIR: /Applications/Xcode_16.1.app/Contents/Developer
2828

2929
jobs:
3030
testMacOS14:
31-
name: "⚗️ macOS (latest)"
32-
runs-on: macos-latest
31+
name: "⚗️ macOS 14 (arm64)"
32+
runs-on: macos-14-arm64
3333

3434
strategy:
3535
fail-fast: true
@@ -39,7 +39,7 @@ jobs:
3939
destination: "platform=iOS Simulator,name=iPhone 15 Pro"
4040
submit_code_coverage: true
4141
- scheme: "PactSwiftMockServer-macOS"
42-
destination: "arch=arm64"
42+
destination: "platform=macOS,arch=arm64"
4343
submit_code_coverage: true
4444

4545
env:
@@ -51,6 +51,13 @@ jobs:
5151
cancel-in-progress: true
5252

5353
steps:
54+
- name: "🏛️ Check runner architecture"
55+
run: |
56+
if [ "$(uname -m)" != "arm64" ]; then
57+
echo -e "🚨 \033[31mThis runner is \033[1mnot arm64\033[0;31m. Failing the job.\033[0m"
58+
exit 1
59+
fi
60+
5461
- name: "♻️ Checkout repository"
5562
uses: actions/checkout@v4
5663
with:
@@ -69,7 +76,7 @@ jobs:
6976
- name: "⚗️ Run tests"
7077
run: |
7178
sh Support/Scripts/Config/prepare_build_tools
72-
sh Support/Scrips/test
79+
sh Support/Scripts/test
7380
7481
- name: "⬆️ Upload coverage reports"
7582
if: ${{ matrix.submit_code_coverage && inputs.submit-coverage-report }}

Support/Scripts/Config/prepare_build_tools

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
set -euo pipefail
2222

2323
# "import"
24-
sourc "${BASH_SOURCE[0]%/*}/../utils.sh"
24+
source "${BASH_SOURCE[0]%/*}/../utils.sh"
2525

2626
brew update
2727

@@ -32,7 +32,7 @@ function brew_install {
3232
echo -e "🍺 Installing $YELLOW$tool$NOCOLOR via Homebrew..."
3333
executeCommand "brew install $tool"
3434
else
35-
echo -e "👍 $LIGHT_BLUE$tool$NOCOLOR is already installed."
35+
echo -e "🍻 $LIGHT_BLUE$tool$NOCOLOR is already installed."
3636
fi
3737
}
3838

Support/Scripts/release

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ function github_create_release_for {
182182
function github_create_pull_request_for_new_version {
183183
local version_tag="$1"
184184
local version_branch="$2"
185-
local pr_message="Release: $version_tag ($REPO_OWNER/$RELEASE_REPO_NAME/releases/tag/$version_tag)"
185+
local pr_message="Release: [$version_tag](https://github.com/$REPO_OWNER/$RELEASE_REPO_NAME/releases/tag/$version_tag)"
186186
local dry_run=; dry_run=$([ "$DRY_RUN" = true ] && echo "--dry-run" || echo "")
187187
local open_pr_cmd="gh pr create --draft --base main --head \"$version_branch\" $dry_run --title \"$version_tag\" --body \"$pr_message\" --repo $REPO_OWNER/$XCPRODUCT_NAME"
188188

0 commit comments

Comments
 (0)