Skip to content

Instantly share code, notes, and snippets.

@fromkk
Last active January 4, 2023 00:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fromkk/979bbd72ab3c637e08031fcba196f32e to your computer and use it in GitHub Desktop.
Save fromkk/979bbd72ab3c637e08031fcba196f32e to your computer and use it in GitHub Desktop.
upload dSYM files without CocoaPods
#!/bin/sh
function help() {
cat <<EOF
$(basename ${0}) is a tool for upload dsyms for Firebase Crashlytics
Usage:
$(basename ${0}) [dsyms/ path] [Google-Service.plist path]
e.g.
$(basename ${0}) "/path/to/dsyms" "/Path/To/GoogleService_info.plist"
EOF
}
cd "$(dirname "$0")"
SCRIPT_PATH="./upload-symbols"
function prepare() {
if [ ! -e $SCRIPT_PATH ]; then
curl -L https://github.com/firebase/firebase-ios-sdk/raw/master/Crashlytics/upload-symbols -o $SCRIPT_PATH
chmod +x $SCRIPT_PATH
fi
}
if [ $# -ne 2 ]; then
help
exit 1
fi
DSYMS_PATH=$1
PLIST_PATH=$2
if [ ! -f "${DSYMS_PATH}" -a ! -d "${DSYMS_PATH}" ]; then
echo "dsyms not found ${DSYMS_PATH}" 1>&2
exit 1
fi
prepare
find "${DSYMS_PATH}" -name "*.dSYM" | xargs -I {} ./upload-symbols -gsp ${PLIST_PATH} -p ios {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment