如何在Windows命令行中使用空格?
cmd /C C:\Program Files (x86)\WinRar\Rar.exe a D:\Hello 2\File.rar D:\Hello 2\*.*
Run Code Online (Sandbox Code Playgroud) OTP 验证适用于调试版本。我还在 firebase 控制台中为发布版本添加了 SHA 密钥。但是当我生成签名的 apk 并将其上传到 Play 商店时,电话身份验证不起作用。在将应用程序上传到 Play 商店的生产环境后,我是否应该同时保留调试 SHA 密钥和发布密钥?在生产环境中使用 Firebase 应用程序是否必须进行 Google App Signing?
我正在使用Firebase Google登录。它可以通过USB调试完美运行。但是,当我生成签名的APK时,它将停止工作。它无法登录。在Android 5.1和Android 6.0.1上使用它。另外,如果Google Play服务未更新,则会提示用户更新该服务,因为该用户可能会退出该应用。如何关闭提示并解决错误?
public class MainActivity extends AppCompatActivity implements GoogleApiClient.OnConnectionFailedListener,
View.OnClickListener {
private Button skip;
private static final String TAG = "GoogleActivity";
private static final int RC_SIGN_IN = 9001;
private ProgressBar pb;
// [START declare_auth]
private FirebaseAuth mAuth;
// [END declare_auth]
// [START declare_auth_listener]
private FirebaseAuth.AuthStateListener mAuthListener;
// [END declare_auth_listener]
private GoogleApiClient mGoogleApiClient;
private TextView mStatusTextView;
private TextView mDetailTextView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
pb=(ProgressBar)findViewById(R.id.signpro);
pb.setVisibility(View.GONE);
skip=(Button)findViewById(R.id.btnskip);
skip.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) …Run Code Online (Sandbox Code Playgroud) 在模拟器和真实设备上进行测试时,Google 登录可以正常工作,但在生产环境中却无法正常工作。我已将 SHA 1 密钥添加到我的 Firestore 项目中。
我该如何解决这个问题?
Future<User> googleSignIn() async {
try {
GoogleSignInAccount googleSignInAccount = await Global.googleSignIn.signIn();
GoogleSignInAuthentication googleAuth =
await googleSignInAccount.authentication;
final AuthCredential credential = GoogleAuthProvider.credential(
accessToken: googleAuth.accessToken,
idToken: googleAuth.idToken,
);
UserCredential result = await Global.fbAuth.signInWithCredential(credential);
User user = result.user;
updateUserData(user);
return user;
} catch (error) {
print(error);
return null;
}
}
Run Code Online (Sandbox Code Playgroud)
onPressed: () async {
showDialogue(context);
var user = await loginMethod();
if (user != null) {
hideProgressDialogue(context);
Navigator.pushReplacementNamed(context, SharedStrings.userInfoPath);
Run Code Online (Sandbox Code Playgroud)
signingConfigs {
release {
keyAlias keystoreProperties['keyAlias']
keyPassword …Run Code Online (Sandbox Code Playgroud) 我正在我的应用程序中实现谷歌登录。我知道在发布应用程序时我必须生成生产就绪的 SHA1 密钥。我使用以下命令做到了这一点。首先,我更改了 .jks 存储在终端中的目录,然后使用以下命令
keytool -list -v -keystore SimplyMap.jks
Run Code Online (Sandbox Code Playgroud)
我在 firebase 中更新了 SHA1。生成签名的 apk 后,我通过 USB 和 google 登录将我的 apk 传输到我的手机,但是一旦我将相同的 apk 上传到 Play 商店,google 登录就无法工作。有人可以帮助我吗?仅供参考,我还使用 Android Studio 生成了 SHA1,但没有成功。我究竟做错了什么?只是为了让您知道 Google Sign in 也可以在调试 apk 中使用。
我的 google 登录我的 flutter 应用程序在 iOS 和 android 模拟器中都可以完美运行,并且在从应用商店下载时在 iOS 中处于发布模式。问题是来自 Play 商店的发布 appbundle 不起作用。当我点击 google 登录按钮时,它会显示我的帐户,我选择了该帐户,它通过并闪烁并返回主屏幕。
我已经运行了 ./gradlew signatureReport 并获得了调试和发布 SHA1 密钥并将它们放置在我的 firebase 控制台中。
我的应用程序级 build.grade 看起来像这样
def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
localPropertiesFile.withReader('UTF-8') { reader ->
localProperties.load(reader)
}
}
def flutterRoot = localProperties.getProperty('flutter.sdk')
if (flutterRoot == null) {
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
}
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
if (flutterVersionCode == null) { …Run Code Online (Sandbox Code Playgroud)