Code Monkey home page Code Monkey logo

plantuml-gradle-plugin's Introduction

plantuml-gradle-plugin

This plugin allows you to convert PlantUML (.puml) files into one of the supported output formats:

Adding the plugin

Kotlin

Using the plugins DSL:

plugins {
    id("io.github.redgreencoding.plantuml") version "x.y.z"
}

Using legacy plugin application:

buildscript {
  repositories {
    maven {
      url = uri("https://plugins.gradle.org/m2/")
    }
  }
  dependencies {
    classpath("io.github.redgreencoding:plantuml-gradle-plugin:x.y.z")
  }
}

apply(plugin = "io.github.redgreencoding.plantuml")

Groovy

Using the plugins DSL:

plugins {
    id "io.github.redgreencoding.plantuml" version "x.y.z"
}

Using legacy plugin application:

buildscript {
  repositories {
    maven {
      url "https://plugins.gradle.org/m2/"
    }
  }
  dependencies {
    classpath "io.github.redgreencoding:plantuml-gradle-plugin:x.y.z"
  }
}

apply plugin: "io.github.redgreencoding.plantuml"

Plugin usage

After adding the plugin to your build you can configure the plugin using the extension block plantuml

Check the supported output formats here.

Kotlin

plantuml {
    options {
        // where should the .svg be generated to (defaults to build/plantuml)
        outputDir = project.file("svg")
        
        // output format (lowercase, defaults to svg)
        format = "svg"
    }

    diagrams {
        create("File1") {
            // .puml sourcefile, this can be also omitted and defaults to _<name>.puml_.
            sourceFile = project.file("doc/File1.puml")
        }

        // this will just look for the file File2.puml
        create("File2")

        // add additional files here
    }
}

Groovy

plantuml {
    options {
        // where should the .svg be generated to (defaults to build/plantuml)
        outputDir = project.file("svg")

        // output format (lowercase, defaults to svg)
        format = "svg"
    }

    diagrams {
        File1 {
            // .puml sourcefile, this can be also omitted and defaults to _<name>.puml_.
            sourceFile = project.file("doc/File1.puml")
        }

        // this will just look for the file File2.puml
        File2

        // add additional files here
    }
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.