Flutter Vs Code里面获得 SHA1 的方法(转)

本文指导你在Flutter项目中使用VSCode获取SHA1密钥,包括步骤说明。遇到Java11版本要求时,提供了解决方案:修改gradle.properties文件以指向正确Java路径。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

How to Get SHA1 Key of Your App in Flutter (VS Code)

All you have to do is follow these steps:

Step 1: Go to your project directory in VS Code.

Step 2: Open terminal.

Step 3: Run “cd android”.

Step 4: Run “.\gradlew signingReport”.

And then tadaa! It will display like that:
在这里插入图片描述
原文地址:
https://nurozkaya.medium.com/how-to-get-sha1-key-of-your-app-in-flutter-vs-code-299e0372ef96

如果出现:

* What went wrong:
A problem occurred evaluating project ':app'.
> Failed to apply plugin 'com.android.internal.application'.
   > Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.
     You can try some of the following options:
       - changing the JAVA_HOME environment variable.
       - changing `org.gradle.java.home` in `gradle.properties`.

最快的修改方法, 最后一句: 在gradle.properties 增加下列代码:

org.gradle.java.home=D:/Program Files/Android/Android Studio/jre

注意后面的路径是你安装AS的有关路径,并注意 / 写法。

是记备忘

MaraSun BJFWDQ
postiive the 8 days, turning normal…

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值