Code Monkey home page Code Monkey logo

lasmanis-maven-tiles's Introduction

Maven Tiles

Branch Status
Master Build Status Maven Central

This project sets up the basic maven infrastructure for projects.

It configures the following basic items for your maven projects:

  • Properties
    • project.build.sourceEncoding
    • project.reporting.outputEncoding
    • maven.compiler.source
    • maven.compiler.target
  • POM elements
    • developers
    • distributionManagement
    • issueManagement
    • license
    • organization
    • scm urls
    • url
  • Plugins
    • clirr-maven-plugin
    • exec-maven-plugin
    • flatten-maven-plugin
    • jacovo-maven-plugin
    • license-maven-plugin
    • maven-antrun-plugin
    • maven-assembly-plugin
    • maven-changes-plugin
    • maven-checkstyle-plugin
    • maven-clean-plugin
    • maven-dependency-plugin
    • maven-deploy-plugin
    • maven-enforcer-plugin
    • maven-gpg-plugin
    • maven-install-plugin
    • maven-jar-plugin
    • maven-javadoc-plugin
    • maven-jxr-plugin
    • maven-pmd-plugin
    • maven-project-info-reports-plugin
    • maven-release-plugin
    • maven-resources-plugin
    • maven-scm-plugin
    • maven-scm-plublish-plugin
    • maven-shade-plugin
    • maven-site-plugin
    • maven-source-plugin
    • maven-surefire-plugin
    • nexus-staging-maven-plugin
    • swagger-maven-plugin
    • templating-maven-plugin
    • versions-maven-plugin

The tile expects the following properties to be set:

  • project.name : the name of the project
  • project.version : the version of the project
  • project.inceptionYear : year the project was starts
  • repository.name : the name of the VCS repository
  • gpg.keyname : key to be used for signing

Tiles can be used individually. Several pre-defined sets are available:

  • core-set-ossrh: Basic POM support with deployment to Maven Central.
  • core-set-nodistribution: Basic POM support without deployment.
  • java-set: Typical JDK8 setup. You should also include a core-set set.

Usage

Below is the basic usage pattern for inclusion in a pom:

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.lasmanis</groupId>
    <artifactId>myartifact</artifactId>
    <version>${revision}.${changelist}</version>

    <packaging>jar</packaging>

    <name>My Project Name</name>
    <description>My Project Description</description>
    <inceptionYear>2020</inceptionYear>

    <properties>
        <revision>0.1</revision>
        <changelist>0-SNAPSHOT</changelist>
        <repository.name>myproject</repository.name>
        <tiles-maven.version>2.19</tiles-maven.version>
        <lasmanis-maven-tiles.version>0.0.0</lasmanis-maven-tiles.version>
    </properties>

    <url>${baseurl}</url>

    <scm>
        <connection>${scmBase.connection}</connection>
        <url>${scmBase.url}</url>
        <developerConnection>${scmBase.developerConnection}</developerConnection>
        <tag>${scmBase.tag}</tag>
    </scm>

    <distributionManagement>
        <site>
           <id>scm-publish</id>
           <url>${scmBase.connection}</url>
       </site>
    </distributionManagement>

    <build>
        <plugins>
            <plugin>
                <groupId>io.repaint.maven</groupId>
                <artifactId>tiles-maven-plugin</artifactId>
                <version>${tiles-maven.version}</version>
                <extensions>true</extensions>
                <configuration>
                    <tiles>
                      <tile>com.lasmanis.maven.tiles:core-set-ossrh:${lasmanis-maven-tiles.version}</tile>
                      <tile>com.lasmanis.maven.tiles:java-set:${lasmanis-maven-tiles.version}</tile>
                    </tiles>
                </configuration>
            </plugin>
        </plugins>
    </build>
</project>

At a minimum, you should update project.artifactId, project.name, repository.name and lasmanis-maven-tiles.version.

gpg.keyname is typically set via a maven settings.xml file or the maven command line (-Dgpg.keyname=GPG_KEY_EMAIL).

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.