diff --git a/README.md b/README.md index aa8cf46..f2cbcdd 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ -#multiproject-git-gradle +# multiproject-git-gradle -##Overview +## Overview This is gradle script for multiple git-repository setup, configuration and build. It supports automated cloning/pulling git-repositories (from any repositories, supported by JGit) and typical gradle tasks ("build", "clean", etc) that can be run against some or all repositories. Repositories can be supplied with inter-repository dependencies, so that particular order of assembly/testing/etc is guaranteed. @@ -45,7 +45,7 @@ which is used by multiproject-git-gradle. * [Publishing to remote maven repo (artifactory)](#publishing-to-remote-maven-repo-artifactory) * [Copyright and License](#copyright-and-license) -##Required files +## Required files To start using multiproject-git-gradle, you need two files: @@ -54,7 +54,7 @@ To start using multiproject-git-gradle, you need two files: "config.gradle" - you write it yourself, according to your needs. You can use "config.gradle" from this repository as an example/starting-point for editing. See more information on this in chapter [Configuration](#configuration). -##Command line syntax +## Command line syntax Like with any other gradle script: @@ -72,9 +72,9 @@ gradle then the default task [buildApps](#buildapps-task) is executed. -##Supported tasks +## Supported tasks -###build task +### build task build task allows to build multiple gradle projects (from different git-repositories) in an automated way. It does the following: @@ -97,7 +97,7 @@ Only if some projects are missing, they will be cloned from git-sources. b) if you run "gradle update build", it is guaranteed, that every project is first updated (cloned or pulled from repository) and only then built. -###buildApps task +### buildApps task buildApps is an optional task, allowing to build "apps" sub-projects of multiple gradle projects (from different git-repositories) in an automated way. It does the following: @@ -110,7 +110,7 @@ Then it iterates all projects described in [configuration](#configuration), perf 2. Tries to perform "gradle build" in [apps sub-folder](#configuring-apps-property) of the project folder. -###buildExamples task +### buildExamples task buildExamples is an optional task, allowing to build "examples" sub-projects of multiple gradle projects (from different git-repositories) in an automated way. It does the following: @@ -123,7 +123,7 @@ Then it iterates all projects described in [configuration](#configuration), perf 2. Tries to perform "gradle build" in [examples sub-folder](#configuring-examples-property) of the project folder. -###clean task +### clean task clean task allows to clean multiple projects (from different git-repositories) in an automated way. @@ -131,11 +131,11 @@ clean task allows to clean multiple projects (from different git-repositories) i TODO: document this task! -###gitStatus task +### gitStatus task TODO: document this task! -###update task +### update task update task allows to clone/pull multiple projects (not necessarily gradle-projects) from git-sources in an automated way. It does the following: @@ -145,7 +145,7 @@ Iterates all projects described in [configuration](#configuration), checks each 2. If project exists, it is pulled from [git-repository](#configuring-git-repositories). -###uploadArchives task +### uploadArchives task TODO: document this task! @@ -155,7 +155,7 @@ This task performs full release process on multiple git projects. See more information at [Automated Release Feature (ARF)](#automated-release-feature). -##Configuration +## Configuration "build.gradle" (of multiproject-git-gradle) reads "config.gradle" file in order to "understand" project structure. "config.gradle" is being interpreted by gradle, therefore it should comply to gradle syntax. @@ -168,7 +168,7 @@ multiproject { } ``` -###Specifying projects +### Specifying projects The simplest usable configuration looks like this: @@ -183,7 +183,7 @@ where ProjectA and ProjectB must designate existing subfolders of the current fo **Effect:** when you run "gradle build", multiproject-git-gradle will consequently build each project specified in multiproject configuration. -###Configuring inter-project dependencies +### Configuring inter-project dependencies You can specify inter-project dependencies the following way: @@ -204,11 +204,11 @@ Rules: * dependsOn is transitive. In the example above, "ProjectD" directly depends on "ProjectB", "ProjectC" and, indirectly, on "ProjectA". -###Configuring git-repositories +### Configuring git-repositories There are two ways to specify git-repositories: via gitBase property and via gitSource property. -####Configuring gitBase property +#### Configuring gitBase property gitBase specifies "base" URL, from where the project(s) come. It supports all protocols supported by JGit library (for example, "http", "https", "git", "ssh"). gitBase can be specified "globally", for project group or for individual projects: @@ -238,7 +238,7 @@ In the concrete example (above) "ProjectA" will be cloned/pulled from "https://g "ProjectB" will be cloned/pulled from "https://github.com/anotherUser/ProjectB.git", "ProjectC" will be cloned/pulled from "https://github.com/anotherUser/ProjectC.git" and "ProjectD" will be cloned/pulled from "https://github.com/thirdUser/ProjectD.git". -####Configuring gitSource property +#### Configuring gitSource property gitSource property represents complete URI to git-repository and is not combined with anything. It supports all protocols supported by JGit library (for example, "http", "https", "git", "ssh"). @@ -261,7 +261,7 @@ gitBase property (either per-project, per-group or global) is ignored for such p In the concrete example (above) "ProjectA" will be cloned/pulled from "https://github.com/someUser/ProjectA.git", "ProjectB" will be cloned/pulled from "https://anotherdomain.com/someDifferentProjectName.git". -####Configuring gitNameSeparator and gitNameSuffix +#### Configuring gitNameSeparator and gitNameSuffix By default, if a project does not have gitSource property, it's effective git repository URI is calculated by formula: URI = gitBase + "/" + name + ".git" @@ -282,7 +282,7 @@ In the concrete example (above) "ProjectA" will be cloned/pulled from "https://g "ProjectB" will be cloned/pulled from "git@someGitoliteRepository:ProjectB", "ProjectC" will be cloned/pulled from "git@someGitoliteRepository:ProjectC". -###Configuring build property +### Configuring build property By default, multiproject-git-gradle builds all projects specified in multiproject configuration. You can fine-tune what and how is built by using "build" property: @@ -306,7 +306,7 @@ Rules: In the concrete example (above) "ProjectA" will be built in "ProjectA" subfolder, "ProjectB" will not be built, "ProjectC" will be built in "ProjectC/subFolder" subfolder. -###Configuring apps property +### Configuring apps property If you specify "apps" property for a given project, multiproject-git-gradle defines additional task "buildApps", which can be called on command line as "gradle buildApps". @@ -328,7 +328,7 @@ which will be run against the combined folder "$projectDir/$apps". * Otherwise "buildApps" task is not defined for the given project. -###Configuring examples property +### Configuring examples property If you specify "examples" property for a given project, multiproject-git-gradle defines additional task "buildExamples", which can be called on command line as "gradle buildExamples". @@ -645,7 +645,7 @@ where "protocol-host-and-port" should be replaced with concrete protocol, host a - commit new version to git - publish new version to remote maven repo -##Copyright and License +## Copyright and License Copyright 2013 (c) Andrey Hihlovskiy