A ZSH theme optimized for people who use:
- Solarized
- Git
- Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)
For Mac users, I highly recommend iTerm 2 + Solarized Dark
| import com.squareup.javapoet.ClassName; | |
| import java.util.HashMap; | |
| /** | |
| * Kotlin 和 Java 类型的映射关系,从 Kotlin 编译器中摘出来 | |
| * Created by benny on 2/5/18. | |
| */ | |
| public class TypesMap { | 
The job2 will throw an ArithmaticException thus making the parent job cancelled. Normally we will get a CancellationException when calling the job2.join() but there is otherwise.
suspend fun main() = runBlocking {
    log(1)
    val job = launch(Dispatchers.Unconfined) {
        log(2)
        val job2 = launch(Dispatchers.Default) {
            log(3)| gradle.taskGraph.afterTask { task -> | |
| StringBuffer taskDetails = new StringBuffer() | |
| taskDetails << """"------------- | |
| name:$task.name group:$task.group : $task.description | |
| conv:$task.convention.plugins | |
| """ | |
| taskDetails << "inputs:\n" | |
| task.inputs.files.each { it -> | |
| taskDetails << "${it.absolutePath}\n" | |
| } | 
| fun RepositoryHandler.enableMirror() { | |
| all { | |
| if (this is MavenArtifactRepository) { | |
| val originalUrl = this.url.toString().removeSuffix("/") | |
| urlMappings[originalUrl]?.let { | |
| logger.lifecycle("Repository[$url] is mirrored to $it") | |
| this.setUrl(it) | |
| } | |
| } | |
| } | 
| -DOHOS_ARCH=arm64-v8a | |
| -DCMAKE_BUILD_TYPE=Debug | |
| -DOHOS_SDK_NATIVE=$SDK_HOME/Sdk/openharmony/10/native | |
| -DCMAKE_SYSTEM_NAME=OHOS | |
| -DCMAKE_OHOS_ARCH_ABI=arm64-v8a | |
| -DCMAKE_EXPORT_COMPILE_COMMANDS=ON | |
| -DCMAKE_TOOLCHAIN_FILE=$SDK_HOME/Sdk/hmscore/4.0.0/native/build/cmake/hmos.toolchain.cmake | |
| -DCMAKE_MAKE_PROGRAM=$SDK_HOME/Sdk/openharmony/10/native/build-tools/cmake/bin/ninja | |
| --no-warn-unused-cli | |
| -DHMOS_SDK_NATIVE=$SDK_HOME/Sdk/hmscore/4.0.0/native |