This file contains hidden or 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
| extra.deps { | |
| "support" { | |
| "appCompat"("com.android.support:appcompat-v7:26.0.2") | |
| "design"("com.android.support:design:26.0.2") | |
| } | |
| "picasso"("com.squareup.picasso:picasso:2.5.2") | |
| } |
This file contains hidden or 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
| dependencies { | |
| compile(deps["support.appCompat"]) | |
| compile(deps["support"]["design"]) | |
| compile(deps["picasso"]) | |
| } |
This file contains hidden or 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
| // global definition in root project | |
| ext.versions = [ | |
| compileSdk: 26, | |
| targetSdk: 25, | |
| … | |
| ] | |
| ext.deps = [ | |
| support: [ | |
| appCompat: “com.android.support:appcompat-v7:${versions.supportLibrary}”, | |
| design: “com.android.support:design:${versions.supportLibrary}”, |
This file contains hidden or 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
| // Declarations | |
| ext["deps"] = mapOf( | |
| "support" to mapOf( | |
| "appCompat" to "com.android.support:appcompat-v7:26.0.2", | |
| "design" to "com.android.support:design:26.0.2" | |
| ), | |
| "picasso" to "com.squareup.picasso:picasso:2.5.2" | |
| ) | |
| // References |
This file contains hidden or 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
| interface DependencyItem | |
| data class DependencyNotation(val notation: String) : DependencyItem | |
| class DependencyGroup : DependencyItem { | |
| val dependencies: Map<String, DependencyItem> | |
| } |
This file contains hidden or 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
| class DependencyGroup { | |
| // provides the `.``[]` operators | |
| operator fun get(key: String): DependencyItem | |
| // provides the `<key>(<notation>)` syntax | |
| operator fun String.invoke(notation: String) | |
| // provides the `<key> {<group>}` syntax | |
| operator fun String.invoke(init: DependencyGroup.() -> Unit) | |
| } |
This file contains hidden or 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
| val ExtraPropertiesExtension.deps: DependencyGroup | |
| get() = | |
| if (has("deps")) this["deps"] as DependencyGroup | |
| else DependencyGroup().apply { | |
| this@deps["deps"] = this | |
| } |
This file contains hidden or 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
| ... | |
| apply from: './flavors.gradle' | |
| ... | |
| android { | |
| buildTypes { | |
| productFlavors { | |
| project.flavors.each { flavor, config -> | |
| "$flavor" { | |
| dimension 'scope' | |
| if (flavor != 'full') { |
This file contains hidden or 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
| Branch/Tag | Desc | Development | Distribution | |
|---|---|---|---|---|
| master | where we commit changes | ✅ | ||
| releases/v{version} | release candidates e.g. releases/v1.0 | ✅ | ||
| v{version} | tags referred from workflows e.g. v1.0 | ✅ |
This file contains hidden or 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
| import * as core from '@actions/core'; | |
| import { context } from '@actions/github'; | |
| import * as request from 'request-promise-native'; | |
| (async function run() { | |
| try { | |
| const botToken = core.getInput('botToken'); | |
| const chatId = core.getInput('chatId'); | |
| const jobStatus = core.getInput('jobStatus'); | |
| const skipSuccess = (core.getInput('skipSuccess') || 'true') === 'true'; |