Skip to content

Commit 6c59e8f

Browse files
committed
PR feedback
1 parent d886635 commit 6c59e8f

File tree

5 files changed

+8
-88
lines changed

5 files changed

+8
-88
lines changed

.github/workflows/test.yml

Lines changed: 3 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,15 @@ jobs:
1515
strategy:
1616
fail-fast: false
1717
matrix:
18-
os: [ubuntu-24.04, macos-14, windows-2022]
18+
os: [ubuntu-24.04, macos-14, windows-2022, macos-14-large]
1919
feature-args: ['', '-Funstable-mobile-app']
2020
include:
2121
- os: ubuntu-24.04
2222
display-os: Linux
2323
- os: macos-14
2424
display-os: macOS
25+
- os: macos-14-large
26+
display-os: macOS (Intel)
2527
- os: windows-2022
2628
display-os: Windows
2729
- feature-args: ''
@@ -41,75 +43,3 @@ jobs:
4143

4244
- name: Run Cargo Tests
4345
run: cargo test --workspace ${{ matrix.feature-args }}
44-
45-
cross-platform-test:
46-
strategy:
47-
fail-fast: false
48-
matrix:
49-
os: [macos-14, macos-14-large]
50-
feature-args: ['', '-Funstable-mobile-app']
51-
include:
52-
- feature-args: ''
53-
feature-suffix: ''
54-
- feature-args: '-Funstable-mobile-app'
55-
feature-suffix: ' (-Funstable-mobile-app)'
56-
57-
name: Build on macOS 14, Test on macOS 13${{ matrix.feature-suffix }}
58-
runs-on: ${{ matrix.os }}
59-
60-
steps:
61-
- name: Checkout Repository
62-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # 4.2.2
63-
64-
- name: Cache Dependencies
65-
uses: swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # 2.8.0
66-
67-
- name: Build on macOS 14
68-
run: cargo build --release --workspace ${{ matrix.feature-args }}
69-
70-
- name: Upload Build Artifacts
71-
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # 4.6.2
72-
with:
73-
name: sentry-cli-macos14-build${{ matrix.feature-suffix }}-${{ matrix.os }}
74-
path: target/release/sentry-cli
75-
retention-days: 1
76-
77-
cross-platform-test-runner:
78-
needs: cross-platform-test
79-
strategy:
80-
fail-fast: false
81-
matrix:
82-
os: [macos-13, macos-13-xlarge, macos-15-large]
83-
feature-args: ['', '-Funstable-mobile-app']
84-
include:
85-
- os: macos-13
86-
base-os: macos-14-large
87-
- os: macos-13-xlarge
88-
base-os: macos-14
89-
- os: macos-15-large
90-
base-os: macos-14-large
91-
- feature-args: ''
92-
feature-suffix: ''
93-
- feature-args: '-Funstable-mobile-app'
94-
feature-suffix: ' (-Funstable-mobile-app)'
95-
96-
name: Run macOS ${{ matrix.os }} ${{ matrix.feature-suffix }}
97-
runs-on: ${{ matrix.os }}
98-
99-
steps:
100-
- name: Checkout Repository
101-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # 4.2.2
102-
103-
- name: Download Build Artifacts
104-
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # 4.3.0
105-
with:
106-
name: sentry-cli-macos14-build${{ matrix.feature-suffix }}-${{ matrix.base-os }}
107-
path: ./bin
108-
109-
- name: Make Binary Executable
110-
run: chmod +x ./bin/sentry-cli
111-
112-
- name: Test Binary Compatibility
113-
run: |
114-
# Ensure the cli runs
115-
./bin/sentry-cli --help

apple-catalog-parsing/build.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,4 @@ fn main() {
9494
println!(
9595
"cargo:rustc-link-search={developer_dir_path}/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx"
9696
);
97-
98-
let lib_dir = "/usr/lib/swift";
99-
println!("cargo:rustc-link-arg=-Wl,-rpath");
100-
println!("cargo:rustc-link-arg=-Wl,{lib_dir}");
10197
}

build.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,5 @@ fn main() -> Result<(), Box<dyn Error>> {
2929
writeln!(f, "pub const USER_AGENT: &str = \"sentry-cli/{arch}\";")?;
3030
println!("cargo:rerun-if-changed=build.rs\n");
3131

32-
// if platform == "darwin" {
33-
// let lib_dir = "/usr/lib/swift";
34-
// println!("cargo:rustc-link-arg=-Wl,-rpath");
35-
// println!("cargo:rustc-link-arg=-Wl,{lib_dir}");
36-
// }
37-
3832
Ok(())
3933
}

src/commands/mobile_app/upload.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ use crate::utils::vcs;
3333
pub fn make_command(command: Command) -> Command {
3434
#[cfg(all(target_os = "macos", target_arch = "aarch64"))]
3535
const HELP_TEXT: &str = "The path to the mobile app files to upload. Supported files include Apk, Aab, XCArchive, and IPA.";
36-
#[cfg(any(not(target_os = "macos"), not(target_arch = "aarch64")))]
36+
#[cfg(not(all(target_os = "macos", target_arch = "aarch64")))]
3737
const HELP_TEXT: &str = "The path to the mobile app files to upload. Supported files include Apk, Aab, and XCArchive.";
3838
command
3939
.about("[EXPERIMENTAL] Upload mobile app files to a project.")
@@ -233,7 +233,7 @@ fn validate_is_mobile_app(path: &Path, bytes: &[u8]) -> Result<()> {
233233
debug!("File format validation failed");
234234
#[cfg(all(target_os = "macos", target_arch = "aarch64"))]
235235
let format_list = "APK, AAB, XCArchive, or IPA";
236-
#[cfg(any(not(target_os = "macos"), not(target_arch = "aarch64")))]
236+
#[cfg(not(all(target_os = "macos", target_arch = "aarch64")))]
237237
let format_list = "APK, AAB, or XCArchive";
238238

239239
Err(anyhow!(

tests/integration/mobile_app/upload.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ use std::sync::atomic::{AtomicBool, Ordering};
44
use std::sync::LazyLock;
55
use std::{fs, str};
66

7-
#[cfg(target_os = "macos")]
7+
#[cfg(all(target_os = "macos", target_arch = "aarch64"))]
88
#[test]
99
fn command_mobile_app_upload_help() {
1010
TestManager::new().register_trycmd_test("mobile_app/mobile_app-upload-help-macos.trycmd");
1111
}
1212

13-
#[cfg(not(target_os = "macos"))]
13+
#[cfg(not(all(target_os = "macos", target_arch = "aarch64")))]
1414
#[test]
1515
fn command_mobile_app_upload_help() {
1616
TestManager::new().register_trycmd_test("mobile_app/mobile_app-upload-help-not-macos.trycmd");
@@ -181,7 +181,7 @@ fn command_mobile_app_upload_apk_chunked() {
181181
}
182182

183183
#[test]
184-
#[cfg(target_os = "macos")]
184+
#[cfg(all(target_os = "macos", target_arch = "aarch64"))]
185185
/// This test simulates a full chunk upload for an IPA file (with only one chunk).
186186
/// It verifies that the Sentry CLI makes the expected API calls to the chunk upload endpoint
187187
/// and that the data sent to the chunk upload endpoint is exactly as expected.

0 commit comments

Comments
 (0)