Skip to content

Commit 291849e

Browse files
committed
not loading token.properties globally anymore.
1 parent 37e3e78 commit 291849e

File tree

2 files changed

+14
-14
lines changed

2 files changed

+14
-14
lines changed

build.gradle

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ if (System.env.JITPACK) {
5050
project.ext.set('version_name', System.env.VERSION)
5151
}
5252

53+
/** Build Configurations */
54+
project.ext.set('archiveBuildTypes', ['debug', 'release'])
55+
5356
/** Keystore Settings, loaded from keystore.properties */
5457
if (rootProject.file('keystore.properties').exists()) {
5558
def keystore = new Properties()
@@ -62,20 +65,6 @@ if (rootProject.file('keystore.properties').exists()) {
6265
project.ext.set('releaseKeyPass', keystore['releaseKeyPass'])
6366
}
6467

65-
/** Build Configurations */
66-
project.ext.set('archiveBuildTypes', ['debug', 'release'])
67-
68-
/** Load API access-token from file `token.properties` */
69-
if(rootProject.file('token.properties').exists()) {
70-
def apikeys = new Properties()
71-
apikeys.load(new FileInputStream(rootProject.file('token.properties')))
72-
project.ext.set('accessToken', apikeys['accessToken'])
73-
} else {
74-
println "*** File `token.properties` is missing; the GitHub API may be rate-limited."
75-
println "*** The personal access token needs to be defined with an EditTextPreference."
76-
project.ext.set('accessToken', "")
77-
}
78-
7968
/** Modules */
8069
allprojects {
8170

mobile/build.gradle

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,17 @@ plugins {
44
id "androidx.navigation.safeargs"
55
}
66

7+
/** Load API access-token from file `token.properties` */
8+
if (rootProject.file('token.properties').exists()) {
9+
def apikeys = new Properties()
10+
apikeys.load(new FileInputStream(rootProject.file('token.properties')))
11+
project.ext.set('accessToken', apikeys['accessToken'])
12+
} else {
13+
println "*** File `token.properties` is missing; the GitHub API may be rate-limited."
14+
println "*** The personal access token needs to be defined with an EditTextPreference."
15+
project.ext.set('accessToken', "")
16+
}
17+
718
base {
819
archivesName = 'github_client_' + rootProject.ext.get('versionName')
920
}

0 commit comments

Comments
 (0)