我正在嘗試在我的應用程式中添加 Paypal。但是,它向我拋出了以下錯誤:
org.gradle.api.GradleScriptException: A problem occurred evaluating root project 'myFirstApp'.
Caused by: groovy.lang.MissingPropertyException: Could not get unknown property 'mavenUsername' for Credentials [username: null] of type org.gradle.internal.credentials.DefaultPasswordCredentials_Decorated.
這是我的 gradle.properties:
android.useAndroidX=true
# Automatically convert third-party libraries to use AndroidX
mavenUsername=paypal_sgerritz
mavenPassword=AKCp8jQ8tAahqpT5JjZ4FRP2mW7GMoFZ674kGqHmupTesKeAY2G8NcmPKLuTxTGkKjDLRzDUQ
并在這里 build.gradle:
allprojects {
repositories {
google()
jcenter()
mavenCentral()
maven {
url "https://jitpack.io"
}
maven {
url "https://cardinalcommerceprod.jfrog.io/artifactory/android"
credentials {
username mavenUsername
password mavenPassword
}
}
}
}
那么,這個庫有什么問題?任何答案將不勝感激。
uj5u.com熱心網友回復:
確保您gradle.properties位于根專案中(或者更確切地說,您的mavenUsername和mavenPassword位于根專案中gradle.properties)
轉載請註明出處,本文鏈接:https://www.uj5u.com/net/425834.html
