Top

Android gradle sync failed with the newer version

Kommentare

3 Kommentare

  • Offizieller Kommentar
    Jordan HIERTZ

    Hello,

    With newer gradle versions you can add the openrainbow repository like this :

    // Inside settings.gradle

    dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
    google()
    mavenCentral()
    jcenter()
    maven { url "https://maven.openrainbow.io" }
    }
    }

     

    // Then the dependencies inside build.gradle
    dependencies {
    implementation 'com.ale:rainbowsdk:2.7.3'
    ...
    }
    Aktionen für Kommentare Permalink
  • Hiro TAKAHASHI

    I followed the instruction in Rainbow API Hub, added lines to my project/build.gradle and app/build.gradle.
    When I hit SyncNow then got this error, "Build was configured to prefer settings repositories over project repositories but repository 'maven' was added by build file.."

    I then moved the line "maven {url "http://maven.openranibow.io"} to settings.gradle, inside the repositories section of the file. But got other errors.

    I googled the errors and found a possible solution that replacing the RepositoriesMode line in the settings.gradle with RepositoriesMode.PREFER_SETTINGS. This modification solved the above sync errors but failed to resolve com.ale:rainbowsdk:2.7.1. I tried other sdk versions such as com.ale:rainbowsdk:1.72.0 but got the same result. 

     

    0
    Aktionen für Kommentare Permalink
  • Hiro TAKAHASHI

    Got it, thank you Jordan!

    0
    Aktionen für Kommentare Permalink

Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.

  • Fragen Sie die Gemeinschaft

    Brauchen Sie Hilfe? Stellen Sie Ihre Fragen in der Community, um Antworten von anderen Rainbow-Benutzern zu erhalten.

    Nachricht posten