Skip to content
This repository has been archived by the owner on Nov 1, 2023. It is now read-only.

Add lane to upload dSyms to Crashlytics #18

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

1nput0utput
Copy link
Contributor

Description

This lane refresh_dsyms will download debug symbols from iTC and upload them to Crashlytics.
It is necessary to have dSyms in Crashlytics to decode a crash stack trace.

Developer must set either CRASHLYTICS_API_TOKEN or GOOGLE_SERVICES_INFO_PLIST_PATH in order to upload the dSyms. The GOOGLE_SERVICE_INFO_PLIST_PATH environment variable is used if you're using Firebase Crashlytics.

@1nput0utput 1nput0utput requested a review from a team March 19, 2018 18:46
Fastfile Outdated
@@ -202,6 +202,18 @@ platform :ios do
!ENV['BITRISE_IO'].nil?
end

desc 'Downloads dSYM from iTuneConnect and upload them to Crashlytics.'
lane :refresh_dsyms do
if ENV['CRASHLYTICS_API_TOKEN'] || ENV['GOOGLE_SERVICES_INFO_PLIST_PATH']

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isn't it the opposite?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rsomlette yes, will change this.

Fastfile Outdated
@@ -202,6 +202,18 @@ platform :ios do
!ENV['BITRISE_IO'].nil?
end

desc 'Downloads dSYM from iTuneConnect and upload them to Crashlytics.'
lane :refresh_dsyms do
if !ENV['CRASHLYTICS_API_TOKEN'] || !ENV['GOOGLE_SERVICES_INFO_PLIST_PATH']
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should also change the || to &&

Copy link
Contributor Author

@1nput0utput 1nput0utput Mar 19, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ccmjz it's either one or the other. If we're using Firebase Crashlytics we have to set GOOGLE_SERVICES_INFO_PLIST_PATH otherwise CRASHLYTICS_API_TOKEN for the original Crashlytics.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So we should raise the error when none of them is set, right? If we use the || here, the error will be raised if one of them is not set.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ccmjz yes, you're right. In my haste, I made this stupid error.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants