AsciidoctorJ GEMs plugin

GEM support is simplified via the org.asciidoctor.jvm.gems.classic plugin.

  • Groovy

  • Kotlin

build.gradle
plugins {
    id 'org.asciidoctor.jvm.gems.classic' version '5.0.0-alpha.2'
}

repositories {
    ruby {
        gems() (1)
    }
}

dependencies {
    asciidoctorGems 'rubygems:asciidoctor-revealjs:1.1.3' (2)
}

asciidoctorj {
    requires 'asciidoctor-revealjs' (3)
}
1 Always specify a GEM proxy. In this case use the internal proxy to rubygems.org.
2 Specify GEMs as per usual.
3 Add the GEM to the project-wide (or task-specific) list of requires.
build.gradle.kts
plugins {
    id("org.asciidoctor.jvm.gems.classic") version "5.0.0-alpha.2"
}

Changing the cache size

By default, the GEM prepare task will only cache the GEM directory if the content is less than 3MB. If you need to use a larger size, then add the following to gradle.properties.

gradle.properties
org.ysb33r.gradle.jruby.api.tasks.gem.cache.limit.mb=15 (1)
1 Set the folder size limit in MB.