I have created flavor builds in the android side of a React Native app. Earlier there was no flavor builds. So I was uploading the source map using CI like this
- run:
name: Upload sourcemaps to Bugsnag
command: |
if [[ $BUGSNAG_KEY ]]; then
yarn generate-source-maps-android upload \
--api-key=$BUGSNAG_KEY \
--app-version=$CIRCLE_BUILD_NUM \
--minifiedFile=android/app/build/generated/assets/react/release/app.bundle \
--source-map=android/app/build/generated/sourcemaps/react/release/app.bundle.map \
--minified-url=app.bundle \
--upload-sources
fi
But now the app is now divided into two flavor builds (play
and foss
) and Bugsnag is available only in play build.
I am getting this error as the source map path needs to be updated.
[error] Error uploading source maps: Error: Source map file does not exist (android/app/build/generated/sourcemaps/react/release/app.bundle.map)
at /home/********/repo/node_modules/bugsnag-sourcemaps/lib/options.js:141:17
I need help in determining what will be the updated path of source map in case of multiple flavors in the app? Thanks in advance.
PS: I Have gone through the docs but didn't find anything related to this scenario.