Open ba246 opened 3 years ago
Me too when i add some things in repositories (in gradle(project)) i get this error
A problem occurred evaluating root project 'MyApp'.
Build was configured to prefer settings repositories over project repositories but repository 'maven' was added by build file 'build.gradle'
edit : It appears that repositories now need to be added in gradle.settings file and not in build.gradle.
Just put it in a repositories block there as usual, or create one if needed.
Adding implementation line still works the same
now i got this error : A problem occurred evaluating settings 'MyApp'.
No signature of method: org.gradle.initialization.DefaultProjectDescriptor.file() is applicable for argument types: (String) values: [github.properties] Possible solutions: find(), find(groovy.lang.Closure), is(java.lang.Object), use([Ljava.lang.Object;), with(groovy.lang.Closure), wait()
i solve this problem in Artic Fox, uff...finally!
@salierykuba can you tell me how cause i have always the same error
// i got mad with the sync error of this library in Artic Fox, and finally resolved it. //add the code below in your settings.gradle, and sync, and you ready to go; Edit where is necessary; i hope this helps //Sorry, for i forgot to paste the solution in the previous message.
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
jcenter() // Warning: this repository is going to shut down soon
maven { url 'https://jitpack.io'}
maven { url 'https://jitpack.io'
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/Cuberto/liquid-swipe-android")
credentials {
username = "here put your github username"
password = "here put your github generated key"
}
}
}
}
// i got mad with the sync error of this library in Artic Fox, and finally resolved it. //add the code below in your settings.gradle, and sync, and you ready to go; Edit where is necessary; i hope this helps //Sorry, for i forgot to paste the solution in the previous message.
dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositories { google() mavenCentral() jcenter() // Warning: this repository is going to shut down soon maven { url 'https://jitpack.io'} maven { url 'https://jitpack.io' name = "GitHubPackages" url = uri("https://maven.pkg.github.com/Cuberto/liquid-swipe-android") credentials { username = "here put your github username" password = "here put your github generated key" } } } }
Hey! @salierykuba but my Android Studio (Electric Eel version) still popup the warning which is -> Failed to resolve: com.cuberto:liquid-swipe:1.0.0 Show in Project Structure dialog Show Details Affected Modules: app Please tell me better solution which runs on my Android Studio (Electric Eel Version) And also tell me where is put this GitHub property -> **def githubProperties = new Properties() githubProperties.load(new FileInputStream(rootProject.file("github.properties"))) repositories { maven { name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/Cuberto/liquid-swipe-android")
credentials {
/** Create github.properties in root project folder file with
** gpr.usr=GITHUB_USER_ID & gpr.key=PERSONAL_ACCESS_TOKEN
** Or set env variable GPR_USER & GPR_API_KEY if not adding a properties file**/
username = githubProperties['gpr.usr'] ?: System.getenv("GPR_USER")
password = githubProperties['gpr.key'] ?: System.getenv("GPR_API_KEY")
}
}
}**
In the Latest version of Android Studio I put this in GradleScript>build.gradle(Project:MyProject) with some changes into dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.PREFER_SETTINGS) repositories { google()
Now , Please tell me how to resolve this issue and run this dependency with freely because I'm stuck in this problem last 6 days but failed to find the adopted solution
// i got mad with the sync error of this library in Artic Fox, and finally resolved it. //add the code below in your settings.gradle, and sync, and you ready to go; Edit where is necessary; i hope this helps //Sorry, for i forgot to paste the solution in the previous message.
dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositories { google() mavenCentral() jcenter() // Warning: this repository is going to shut down soon maven { url 'https://jitpack.io'} maven { url 'https://jitpack.io' name = "GitHubPackages" url = uri("https://maven.pkg.github.com/Cuberto/liquid-swipe-android") credentials { username = "here put your github username" password = "here put your github generated key" } } } }
Hey! @salierykuba but my Android Studio (Electric Eel version) still popup the warning which is -> Failed to resolve: com.cuberto:liquid-swipe:1.0.0 Show in Project Structure dialog Show Details Affected Modules: app Please tell me better solution which runs on my Android Studio (Electric Eel Version) And also tell me where is put this GitHub property -> **def githubProperties = new Properties() githubProperties.load(new FileInputStream(rootProject.file("github.properties"))) repositories { maven { name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/Cuberto/liquid-swipe-android") credentials { /** Create github.properties in root project folder file with ** gpr.usr=GITHUB_USER_ID & gpr.key=PERSONAL_ACCESS_TOKEN ** Or set env variable GPR_USER & GPR_API_KEY if not adding a properties file**/ username = githubProperties['gpr.usr'] ?: System.getenv("GPR_USER") password = githubProperties['gpr.key'] ?: System.getenv("GPR_API_KEY") } } }**
In the Latest version of Android Studio I put this in GradleScript>build.gradle(Project:MyProject) with some changes into dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.PREFER_SETTINGS) repositories { google()
Now , Please tell me how to resolve this issue and run this dependency with freely because I'm stuck in this problem last 6 days but failed to find the adopted solution
got anything bro?? >﹏<
When i am trying to add liquid swipe in new Arctic Fox android studio,It gives me error, Please help me