【发布时间】:2016-09-07 20:12:16
【问题描述】:
我在尝试在build.gradle 文件中添加db.properties 文件时遇到此错误
build.gradle:
allprojects {
apply from: 'db.properties'
apply from: 'deployment.properties'
repositories {
mavenCentral()
}
apply plugin: 'java'
apply plugin: 'war'
apply plugin: 'maven-publish'
apply plugin: 'idea'
sourceCompatibility = 1.8
}
db.properties:
db=blal
dbUsername=/bilal/home
我得到的错误是:
* Where:
Script 'camelawsextractionservicesb/db.properties' line: 1
* What went wrong:
A problem occurred evaluating script.
> Could not find property 'blal' on root project 'CamelExtractionServices'.
【问题讨论】:
-
你不能
apply from属性文件。 -
上个月关闭了该设施的 JIRA 功能请求。我把我的两个鲍勃的价值放在这里:Support loading of named ".properties" files as project properties -- 欢迎评论和改进。最重要的是,我认为 Gradle 的人们需要投票才能让事情发生。
标签: gradle build.gradle