Instantly share code, notes, and snippets.

View mdocBasics.groovy
import metridoc.core.Step
step(foo: "I am foo") {
println "I am from foo"
step(bar: "I am bar") {
depends "foo"
println "I am from foo"
View LdapExample.groovy
import javax.naming.Context
* Created with IntelliJ IDEA on 7/18/13
* @author Tommy Barker
def config = new ConfigSlurper().parse(new File("${System.getProperty("user.home")}/.metridoc/MetridocConfig.groovy").toURI().toURL())
View gist:5825298
class BintrayGenericUpload extends DefaultTask {
File artifactFile
String artifactUrl
def publish() {
View gist:5684208
task uploadToBintray(dependsOn: ["prepareForBintrayUpload", "publishBintrayPackages"])
task prepareForBintrayUpload << {
if (version.contains("SNAPSHOT")) {
println "bintray does not support SNAPSHOTs, skipping upload to bintray"
uploadArchives.enabled = false
publishBintrayPackages.enabled = false
View gist:5629664
import groovy.json.JsonBuilder
//make sure you have installed groovy
//best way to install groovy:
def carRecords = '''
<car name='HSV Maloo' make='Holden' year='2006'>