build.gradle

“gradle publish” wrongly reporting up-to-date

故事扮演 提交于 2019-12-06 05:40:00
I'm trying to build Apache S4 and publish it to our Nexus repository. gradle publishToMavenLocal worked, so I added publishing { repositories { maven { credentials { username "admin" password "admin123" } url "http://127.0.0.1:9081/nexus/content/repositories/releases/" } } } to build.gradle after apply plugin: 'maven-publish' . This worked for other projects on the same machine. However, now I get aromanov@ws:~/etc/apache-s4-0.6.0$ gradle clean publish Build file '/home/aromanov/etc/apache-s4-0.6.0/subprojects/s4-benchmarks/s4-benchmarks.gradle': line 42 The RepositoryHandler.mavenRepo()

Issue with experimental gradle: The android plugin must be applied to the project

ぐ巨炮叔叔 提交于 2019-12-06 05:15:16
问题 I'm trying to run some native code with the NDK in Android Studio. I have followed the steps shown HERE to use the experimental Gradle, but obviously it's not all going smoothly. I'm getting this error: The android or android-library plugin must be applied to the project Here is my gradle file: apply plugin: 'com.android.model.application' apply plugin: 'com.neenbedankt.android-apt' apply plugin: 'io.fabric' model { android { compileSdkVersion = 22 buildToolsVersion = "22.0.1" android.ndk {

Android Gradle Dependency

怎甘沉沦 提交于 2019-12-06 05:07:39
I am using local aar files for one of our projects and have below Query. I have 2 libraries and 1 application. 2 libraries are: 1. TestLib2 2. TestLib1 1 Application is: 1. Test I use a aar file created for TestLib2 and refer it using flatDir in TestLib1. I can access the functions present in TestLib2 without any problems. Now I use a aar file created for TestLib1 and refer it using flatDir in Test. I can access only the functions present in TestLib1. For accessing TestLib2 i have to add it to Test application as one more Library. So the dependency is like below: Test |_ TestLib1 |_ TestLib2

How to configure build.gradle files of an existing project with actionbarsherlock lib?

梦想与她 提交于 2019-12-06 04:36:23
问题 I have an existing project MyProject in eclipse that use the library actionbarsherlock (version 4.3.1). The project compiles and runs in android studio, but I don't get build variants. Please help! Here is setting.gradle and build.gradle of my root folder (project_workspace): // setting.gradle: include ':MyProject' include ':actionbarsherlock' build.grade: buildscript { repositories { mavenCentral() } dependencies { classpath 'com.android.tools.build:gradle:gradle:0.4' } } build.gradle of

Gradle plugin 3.0 rewrite versionName

回眸只為那壹抹淺笑 提交于 2019-12-06 03:57:04
问题 I migrated to Android studio 3 and using gradle plugin v3.0.0-beta6. I would like to rewrite versionName/vesionCode of output .apk files. I used following code for gradle plugin 2.x in the build.gradle of my Android app module applicationVariants.all { variant -> def flavor = variant.mergedFlavor flavor.versionName="${VERSION_NAME}" if (variant.buildType.isDebuggable()) { flavor.versionCode=9999 } else { flavor.versionCode=Integer.parseInt(gitCommitCount) } } It doesn't work on gradle plugin

Plugin is too old, please update to a more recent version, or set ANDROID_DAILY_OVERRIDE environment variable

眉间皱痕 提交于 2019-12-06 03:08:33
Showing this error on running my project, I tried all the solution available but it's not working. The only thing left is to set the ANDROID_DAILY_OVERRIDE environment variable, but I am struggling to do so. How I can set ANDROID_DAILY_OVERRIDE environment variable on a mac? Change your build.gradle file to classpath 'com.android.tools.build:gradle:2.0.0-alpha6' Also navigate to to yourProjectPath/Gradle/wrapper and open the gradle-wrapper.properties Change distributionURL with distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip I hope this helps Since you asked how

What is “postprocessing” block inside the 'release' block in app level gradle file in Android Studio?

流过昼夜 提交于 2019-12-06 02:55:50
问题 Below is the snipet of app level gradle file. buildTypes { release { postprocessing { removeUnusedCode false removeUnusedResources false obfuscate false optimizeCode false proguardFile 'proguard-rules.pro' } } } Here, 'postprocessing' seems new in the gradle file. What does it mean? Android studio shows error while adding 'setMinifyEnabled true' along with it. Studio Error: Error:The setMinifyEnabled true method cannot be used with together with the postprocessing 回答1: postprocessing block

Error:(19, 0) Gradle DSL method not found: 'android()'

只愿长相守 提交于 2019-12-06 02:49:23
问题 Android Studio is giving this error while compiling the project. I have searched and found that this may happen because of android Block in top of the build.gradle.But in my build.gradle it may be not the problem. here is my gradle files. build.gradle // Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { repositories { jcenter() } dependencies { classpath 'com.android.tools.build:gradle:1.1.0' // NOTE: Do not place your application

gradle 1.10 internal maven repository indexing forever in intellij 13

こ雲淡風輕ζ 提交于 2019-12-06 02:49:04
问题 I have two projects. One Maven and one Gradle. The company also has an internal maven repository. I am trying to setup Gradle to use the internal repo. Using Intellij 13, when I add the repo like so to Gradle in build.gradle build.gradle file : apply plugin: 'java' apply plugin: 'war' sourceCompatibility = 1.5 version = '1.0' maven { url "http://nexus.company.com/nexus/repo" } mavenLocal() mavenCentral() maven { url "https://oss.sonatype.org/content/repositories/snapshots" } The .m2/settings

Gradle build error: Failed to resolve:

为君一笑 提交于 2019-12-06 02:33:19
问题 I just downloaded Android Studio and created a new project and I'm getting gradle build errors: Failed to resolve: com.android.support.test.espresso-core:2.2.2 and Failed to resolve: com.android.support.appcompat-v7:25.3.1 This error was resolved reinstalling the SDK Tools + Repository + API when launching android studio as admin. I've installed API Level 25 which what I want to build on and have downloaded the SDK Build-Tools. I have also already download the support repository Here's my app