質問編集履歴
1
gradle
test
CHANGED
File without changes
|
test
CHANGED
@@ -75,3 +75,161 @@
|
|
75
75
|
|
76
76
|
|
77
77
|
宜しくお願い致します。
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
2018/09/19 追記
|
82
|
+
|
83
|
+
Ankoへの参照がうまくいってないのでしょうか?
|
84
|
+
|
85
|
+
gradleのコードを追記します。
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
\AlarmApp\build.gradle
|
92
|
+
|
93
|
+
※ この1行を追加しました→ext.anko_version = '0.10.4'
|
94
|
+
|
95
|
+
```java
|
96
|
+
|
97
|
+
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
98
|
+
|
99
|
+
|
100
|
+
|
101
|
+
buildscript {
|
102
|
+
|
103
|
+
ext.kotlin_version = '1.2.61'
|
104
|
+
|
105
|
+
ext.anko_version = '0.10.4' //これを追加
|
106
|
+
|
107
|
+
repositories {
|
108
|
+
|
109
|
+
google()
|
110
|
+
|
111
|
+
jcenter()
|
112
|
+
|
113
|
+
}
|
114
|
+
|
115
|
+
dependencies {
|
116
|
+
|
117
|
+
classpath 'com.android.tools.build:gradle:3.1.3'
|
118
|
+
|
119
|
+
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
// NOTE: Do not place your application dependencies here; they belong
|
124
|
+
|
125
|
+
// in the individual module build.gradle files
|
126
|
+
|
127
|
+
}
|
128
|
+
|
129
|
+
}
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
allprojects {
|
134
|
+
|
135
|
+
repositories {
|
136
|
+
|
137
|
+
google()
|
138
|
+
|
139
|
+
jcenter()
|
140
|
+
|
141
|
+
}
|
142
|
+
|
143
|
+
}
|
144
|
+
|
145
|
+
|
146
|
+
|
147
|
+
task clean(type: Delete) {
|
148
|
+
|
149
|
+
delete rootProject.buildDir
|
150
|
+
|
151
|
+
}
|
152
|
+
|
153
|
+
|
154
|
+
|
155
|
+
```
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
AlarmApp\app\build.gradle
|
160
|
+
|
161
|
+
※この1行を追加しました→implementation "org.jetbrains.anko:anko-commons:$anko_version"
|
162
|
+
|
163
|
+
```java
|
164
|
+
|
165
|
+
apply plugin: 'com.android.application'
|
166
|
+
|
167
|
+
|
168
|
+
|
169
|
+
apply plugin: 'kotlin-android'
|
170
|
+
|
171
|
+
|
172
|
+
|
173
|
+
apply plugin: 'kotlin-android-extensions'
|
174
|
+
|
175
|
+
|
176
|
+
|
177
|
+
android {
|
178
|
+
|
179
|
+
compileSdkVersion 28
|
180
|
+
|
181
|
+
defaultConfig {
|
182
|
+
|
183
|
+
applicationId "com.example.administrator.alarmapp"
|
184
|
+
|
185
|
+
minSdkVersion 21
|
186
|
+
|
187
|
+
targetSdkVersion 28
|
188
|
+
|
189
|
+
versionCode 1
|
190
|
+
|
191
|
+
versionName "1.0"
|
192
|
+
|
193
|
+
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
194
|
+
|
195
|
+
}
|
196
|
+
|
197
|
+
buildTypes {
|
198
|
+
|
199
|
+
release {
|
200
|
+
|
201
|
+
minifyEnabled false
|
202
|
+
|
203
|
+
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
204
|
+
|
205
|
+
}
|
206
|
+
|
207
|
+
}
|
208
|
+
|
209
|
+
}
|
210
|
+
|
211
|
+
|
212
|
+
|
213
|
+
dependencies {
|
214
|
+
|
215
|
+
implementation "org.jetbrains.anko:anko-commons:$anko_version" //これを追加
|
216
|
+
|
217
|
+
implementation fileTree(dir: 'libs', include: ['*.jar'])
|
218
|
+
|
219
|
+
implementation"org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
|
220
|
+
|
221
|
+
implementation 'com.android.support:appcompat-v7:28.0.0-rc02'
|
222
|
+
|
223
|
+
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
|
224
|
+
|
225
|
+
testImplementation 'junit:junit:4.12'
|
226
|
+
|
227
|
+
androidTestImplementation 'com.android.support.test:runner:1.0.2'
|
228
|
+
|
229
|
+
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
|
230
|
+
|
231
|
+
}
|
232
|
+
|
233
|
+
|
234
|
+
|
235
|
+
```
|