Skip to content

Commit a363962

Browse files
committed
Better handling of bintray credentials
1 parent 5ef0bba commit a363962

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,3 @@ build
33
*.iws
44
*.iml
55
.gradle
6-
local.properties

build.gradle

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,9 @@ def siteUrl = 'https://github.com/egulias/EmailValidator4J'
2525
def gitUrl = 'https://github.com/egulias/EmailValidator4J.git'
2626
group = "egulias"
2727

28-
Properties properties = new Properties()
29-
properties.load(project.rootProject.file('local.properties').newDataInputStream())
28+
String getProperty (String name, String value) {
29+
project.hasProperty (name)? project.property (name) : value
30+
}
3031

3132

3233
task createPom << {
@@ -49,8 +50,8 @@ task createPom << {
4950
}
5051

5152
bintray {
52-
user = properties.getProperty("bintray.user")
53-
key = properties.getProperty("bintray.apikey")
53+
user = getProperty("bintray.user", "anon")
54+
key = getProperty("bintray.apikey", "anon")
5455

5556
configurations = ['archives']
5657
pkg {

0 commit comments

Comments
 (0)