SHA1 Key for DEBUG & RELEASE ANDROID STUDIO MAC

匿名 (未验证) 提交于 2019-12-03 03:07:02

问题:

How do I get my SHA1 Keys for debug and release using android studio on a mac? (These are required for Google API Keys)

回答1:

DEBUG:

  1. Click on the Gradle tab on the right hand side of the view.

  2. Go to the ROOT folder -> Tasks -> android -> signingReport

  3. Double click, this will build with the signingReport and post in your bottom view your SHA1.

RELEASE:

  1. In android studio. Build -> Generate Signed APK... and click Next

  2. Copy your key store path and key alias.

  1. Traverse to the "bin" folder of the jdk path present in Java.

  2. Open terminal and enter:

    keytool -list -v -keystore "key store path" -alias "key alias"

  3. Enter your key password and this will print out your release SHA1.



回答2:

To obtain SHA1 for DEBUG as well as RELEASE you have to add the key details in the signingConfigs of your gradle file,

see the example here



标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!