Adrian Adrian - 1 year ago 190
Android Question

Gradle does not find property for Properties file in Android Studio

I have run into this problem when I wanted to make a release build of my android app. This worked fine a couple of days ago but now it dosnt seem to work for some reason. I haven't touched the file gradle file except for adding the second compile dependancie for Picasso lib. The properties file hasn't been changed and neither the keystore.

This is what I get whe trying to build.

Error:A problem was found with the configuration of task ':app:packageRelease'.
> File 'C:\Users\MyName\AndroidStudioProjects\MyApp\app\'\C:\Users\MyName\Documents\keystores\android.keystore'' specified for property 'signingConfig.storeFile' does not exist.


apply plugin: ''

android {
signingConfigs {
compileSdkVersion 17
buildToolsVersion "21.1.1"
defaultConfig {
applicationId "org.happymtb.unofficial"
minSdkVersion 16
targetSdkVersion 17
signingConfig signingConfigs.releaseConfig
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
productFlavors {

dependencies {
compile ''
compile 'com.squareup.picasso:picasso:2.5.2'

def Properties props = new Properties()
def propFile = file('../')
if (propFile.canRead()){
props.load(new FileInputStream(propFile))

if (props!=null && props.containsKey('STORE_FILE') && props.containsKey('STORE_PASSWORD') &&
props.containsKey('KEY_ALIAS') && props.containsKey('KEY_PASSWORD')) {

android.signingConfigs.releaseConfig.storeFile = file(props['STORE_FILE'])
android.signingConfigs.releaseConfig.storePassword = props['STORE_PASSWORD']
android.signingConfigs.releaseConfig.keyAlias = props['KEY_ALIAS']
android.signingConfigs.releaseConfig.keyPassword = props['KEY_PASSWORD']
} else {
android.buildTypes.releaseConfig.signingConfig = null
}else {
android.buildTypes.release.signingConfig = null


Answer Source

Managed to solve it by updating all the libs. Cleanung/rebuilding the project alot of times and changing file to this (basically removing all '):

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download