Skip to content

Commit 17c80bd

Browse files
committed
final fixes
1 parent 73967a5 commit 17c80bd

File tree

2 files changed

+6
-10
lines changed

2 files changed

+6
-10
lines changed

.github/workflows/publish.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -221,21 +221,21 @@ jobs:
221221

222222
- name: Upload debug symbols to Sentry
223223
if: ${{ runner.os == 'macOS' }}
224+
shell: bash
224225
env:
225226
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
226-
working-directory: target
227227
run: |
228228
curl -sL https://sentry.io/get-cli/ | bash
229-
sentry-cli debug-files upload -o ${{ env.SENTRY_ORG }} -p ${{ env.SENTRY_PROJECT }} Cap.dSYM
229+
sentry-cli debug-files upload -o ${{ env.SENTRY_ORG }} -p ${{ env.SENTRY_PROJECT }} target/Cap.dSYM
230230
231231
- name: Upload debug symbols to Sentry
232232
if: ${{ runner.os == 'Windows' }}
233+
shell: bash
233234
env:
234235
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
235-
working-directory: target
236236
run: |
237237
curl -sL https://sentry.io/get-cli/ | bash
238-
sentry-cli debug-files upload -o ${{ env.SENTRY_ORG }} -p ${{ env.SENTRY_PROJECT }} release/cap_desktop.pdb
238+
sentry-cli debug-files upload -o ${{ env.SENTRY_ORG }} -p ${{ env.SENTRY_PROJECT }} target/${{ matrix.settings.target }}/release/cap_desktop.pdb
239239
240240
done:
241241
needs: [draft, build]

apps/desktop/src-tauri/src/main.rs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ fn main() {
1414
}
1515

1616
// We have to hold onto the ClientInitGuard until the very end
17-
let _guard = std::option_env!("CAP_DESKTOP_SENTRY_URL").map(|url| {
17+
let _sentry_guard = std::option_env!("CAP_DESKTOP_SENTRY_URL").map(|url| {
1818
let sentry_client = sentry::init((
1919
url,
2020
sentry::ClientOptions {
@@ -48,8 +48,6 @@ fn main() {
4848

4949
(sentry_client, _guard)
5050
});
51-
// Keep the guard alive for the duration of the program
52-
std::mem::forget(_guard);
5351

5452
let (layer, handle) = tracing_subscriber::reload::Layer::new(None::<DynLoggingLayer>);
5553

@@ -75,9 +73,7 @@ fn main() {
7573
});
7674

7775
let file_appender = tracing_appender::rolling::daily(&logs_dir, "cap-desktop.log");
78-
let (non_blocking, _guard) = tracing_appender::non_blocking(file_appender);
79-
// Keep the guard alive for the duration of the program
80-
std::mem::forget(_guard);
76+
let (non_blocking, _logger_guard) = tracing_appender::non_blocking(file_appender);
8177

8278
let registry = tracing_subscriber::registry().with(tracing_subscriber::filter::filter_fn(
8379
(|v| v.target().starts_with("cap_")) as fn(&tracing::Metadata) -> bool,

0 commit comments

Comments
 (0)