Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into jmatsu-patch-1
- Loading branch information
Showing
148 changed files
with
1,787 additions
and
746 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -eu | ||
|
||
: "${MAX_RETRY_COUNT:=3}" | ||
|
||
retry() { | ||
local retry=0 | ||
|
||
while let "$MAX_RETRY_COUNT > $retry"; do | ||
let "retry=$retry+1" | ||
|
||
"$@" && exit 0 | ||
|
||
sleep 3 | ||
done | ||
|
||
echo "Failed to process : $@" 1>&2 | ||
exit 1 | ||
} | ||
|
||
retry "$@" |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
...api-impl/src/commonMain/kotlin/io/github/droidkaigi/confsched2019/data/api/ApiEndpoint.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package io.github.droidkaigi.confsched2019.data.api | ||
|
||
internal expect fun apiEndpoint(): String |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
data/api-impl/src/iosMain/kotlin/io/github/droidkaigi/confsched2019/data/api/ApiComponent.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package io.github.droidkaigi.confsched2019.data.api | ||
|
||
import io.ktor.client.HttpClient | ||
import io.ktor.client.engine.ios.Ios | ||
import io.ktor.client.features.UserAgent | ||
import platform.Foundation.NSBundle | ||
|
||
// TODO: Replace with DI tools. | ||
internal fun generateHttpClient(): HttpClient { | ||
val version = NSBundle.mainBundle.objectForInfoDictionaryKey("CFBundleShortVersionString") as String | ||
return HttpClient(Ios) { | ||
install(UserAgent) { | ||
agent = "official-app-2019/$version" | ||
} | ||
} | ||
} | ||
|
||
fun generateDroidKaigiApi(): DroidKaigiApi { | ||
return KtorDroidKaigiApi(generateHttpClient(), apiEndpoint()) | ||
} | ||
|
||
fun generateGoogleFormApi(): GoogleFormApi { | ||
return KtorGoogleFormApi(generateHttpClient()) | ||
} |
5 changes: 5 additions & 0 deletions
5
data/api-impl/src/iosMain/kotlin/io/github/droidkaigi/confsched2019/data/api/ApiEndpoint.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package io.github.droidkaigi.confsched2019.data.api | ||
|
||
// TODO: Replace with code getting endpoint from iOS application build configurations. | ||
// This is temporally implementation. | ||
internal actual fun apiEndpoint(): String = "https://droidkaigi2019-dev.appspot.com/api" |
5 changes: 5 additions & 0 deletions
5
data/api-impl/src/main/java/io/github/droidkaigi/confsched2019/data/api/ApiEndpoint.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package io.github.droidkaigi.confsched2019.data.api | ||
|
||
import io.github.droidkaigi.confsched2019.api.BuildConfig | ||
|
||
internal actual fun apiEndpoint(): String = BuildConfig.API_ENDPOINT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 0 additions & 25 deletions
25
...i/src/androidTest/java/io/github/droidkaigi/confsched2019/ui/ExampleInstrumentedTest.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.