Skip to content

Instantly share code, notes, and snippets.

View ologe's full-sized avatar
💭
I may be slow to respond.

Eugeniu Olog ologe

💭
I may be slow to respond.
View GitHub Profile
@xinthink
xinthink / build.gradle
Created September 5, 2018 10:16 — forked from gpeal/build.gradle
Airbnb Gradle Flavors
...
apply from: './flavors.gradle'
...
android {
buildTypes {
productFlavors {
project.flavors.each { flavor, config ->
"$flavor" {
dimension 'scope'
if (flavor != 'full') {
@raulraja
raulraja / TwitterHandle.kt
Created February 20, 2020 12:16
Type Refinements with Type Proofs in Kotlin
/* Coming up ~ April 2020 */
package test
import arrow.*
inline class TwitterHandle(val handle: String) {
companion object : Refined<String> {
override val validate: String.() -> Map<String, Boolean> = {
mapOf(
"Should start with '@'" to startsWith("@"),
@cortinico
cortinico / Kotlin.xml
Created April 6, 2020 15:00
.debug -> .also(::println) Live Template
<templateSet group="Kotlin">
<template name="debug" value="also(::println)" description="Print a debug log" toReformat="false" toShortenFQNames="true">
<context>
<option name="KOTLIN" value="true" />
<option name="KOTLIN_COMMENT" value="false" />
<option name="KOTLIN_TOPLEVEL" value="false" />
</context>
</template>
</templateSet>