Skip to content

add logic to support SENTRY_PROPERTIES parameter #14

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 15, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/bundle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,14 @@
const bundleParams = await checkPlugins();
const isSentry = bundleParams.sentry;

if (isSentry) {
if (platform === 'ios') {
process.env.SENTRY_PROPERTIES = 'ios/sentry.properties';
} else if (platform === 'android') {
process.env.SENTRY_PROPERTIES = 'android/sentry.properties';
}
}

let bundleCommand = 'bundle';
if (usingExpo) {
bundleCommand = 'export:embed';
Expand Down Expand Up @@ -528,16 +536,16 @@
return new Promise((resolve, reject) => {
zipFile.openReadStream(entry, (err, stream) => {
stream.pipe({
write(chunk: Buffer) {

Check failure on line 539 in src/bundle.ts

View workflow job for this annotation

GitHub Actions / lint (20.x)

Type '(chunk: Buffer<ArrayBufferLike>) => void' is not assignable to type '{ (buffer: string | Uint8Array<ArrayBufferLike>, cb?: ((err?: Error | null | undefined) => void) | undefined): boolean; (str: string, encoding?: BufferEncoding | undefined, cb?: ((err?: Error | ... 1 more ... | undefined) => void) | undefined): boolean; (buffer: string | Uint8Array<...>, cb?: ((err?: Error | ... 1 m...'.
buffers.push(chunk);
},
end() {

Check failure on line 542 in src/bundle.ts

View workflow job for this annotation

GitHub Actions / lint (20.x)

Type '() => void' is not assignable to type '{ (cb?: (() => void) | undefined): WritableStream; (data: string | Uint8Array<ArrayBufferLike>, cb?: (() => void) | undefined): WritableStream; (str: string, encoding?: BufferEncoding | undefined, cb?: (() => void) | undefined): WritableStream; (cb?: (() => void) | undefined): WritableStream; (data: string | Uint8Ar...'.
resolve(Buffer.concat(buffers));
},
prependListener() {},

Check failure on line 545 in src/bundle.ts

View workflow job for this annotation

GitHub Actions / lint (20.x)

Type '<K>() => void' is not assignable to type '{ <K>(eventName: string | symbol, listener: (...args: any[]) => void): WritableStream; <K>(eventName: string | symbol, listener: (...args: any[]) => void): WritableStream; }'.
on() {},

Check failure on line 546 in src/bundle.ts

View workflow job for this annotation

GitHub Actions / lint (20.x)

Type '<K>() => void' is not assignable to type '{ <K>(eventName: string | symbol, listener: (...args: any[]) => void): WritableStream; <K>(eventName: string | symbol, listener: (...args: any[]) => void): WritableStream; }'.
once() {},

Check failure on line 547 in src/bundle.ts

View workflow job for this annotation

GitHub Actions / lint (20.x)

Type '<K>() => void' is not assignable to type '{ <K>(eventName: string | symbol, listener: (...args: any[]) => void): WritableStream; <K>(eventName: string | symbol, listener: (...args: any[]) => void): WritableStream; }'.
emit() {},

Check failure on line 548 in src/bundle.ts

View workflow job for this annotation

GitHub Actions / lint (20.x)

Type '<K>() => void' is not assignable to type '{ <K>(eventName: string | symbol, ...args: AnyRest): boolean; <K>(eventName: string | symbol, ...args: AnyRest): boolean; }'.
});
});
});
Expand All @@ -556,7 +564,7 @@

let originSource: Buffer | undefined;

await enumZipEntries(origin, (entry, zipFile) => {

Check failure on line 567 in src/bundle.ts

View workflow job for this annotation

GitHub Actions / lint (20.x)

Argument of type '(entry: Entry, zipFile: ZipFile) => Promise<any> | undefined' is not assignable to parameter of type '(entry: Entry, zipFile: ZipFile, nestedPath?: string | undefined) => Promise<any>'.
originEntries[entry.fileName] = entry;
if (!/\/$/.test(entry.fileName)) {
// isFile
Expand Down
Loading