| | |
| | | <?xml version="1.0" encoding="UTF-8"?>
|
| | | <project name="gitblit" default="compile" basedir=".">
|
| | |
|
| | | <!-- Google Code upload task -->
|
| | | <taskdef classname="net.bluecow.googlecode.ant.GoogleCodeUploadTask" |
| | | classpath="${basedir}/tools/ant-googlecode-0.0.3.jar" name="gcupload"/>
|
| | |
|
| | | <!-- GenJar task -->
|
| | | <taskdef resource="genjar.properties" classpath="${basedir}/tools/GenJar.jar" />
|
| | |
|
| | | <!-- Project Properties -->
|
| | | <property name="project.jar" value="gitblit.jar" />
|
| | | <property name="project.mainclass" value="com.gitblit.Launcher" />
|
| | | <property name="project.build.dir" value="${basedir}/build" />
|
| | | <property name="project.deploy.dir" value="${basedir}/deploy" />
|
| | | <property name="project.war.dir" value="${basedir}/war" />
|
| | | <property name="project.site.dir" value="${basedir}/site" />
|
| | | <property name="project.resources.dir" value="${basedir}/resources" /> |
| | | <property name="project.express.dir" value="${basedir}/express" />
|
| | | <available property="hasBuildProps" file="${basedir}/build.properties"/>
|
| | | <project name="gitblit" default="compile" xmlns:mx="antlib:org.moxie">
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Load build.properties, if available
|
| | | Retrieve Moxie Toolkit
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildprops" if="hasBuildProps">
|
| | | <!-- Load publication servers, paths, and credentials --> |
| | | <loadproperties>
|
| | | <file file="${basedir}/build.properties" />
|
| | | </loadproperties>
|
| | | </target>
|
| | | <property name="moxie.version" value="0.7.1" />
|
| | | <property name="moxie.url" value="http://gitblit.github.com/moxie/maven" />
|
| | | <property name="moxie.jar" value="moxie-toolkit-${moxie.version}.jar" />
|
| | | <property name="moxie.dir" value="${user.home}/.moxie" />
|
| | |
|
| | | <!-- Download Moxie from it's Maven repository to user.home -->
|
| | | <get src="${moxie.url}/org/moxie/moxie-toolkit/${moxie.version}/${moxie.jar}"
|
| | | dest="${moxie.dir}" skipexisting="true" verbose="true" />
|
| | | |
| | | <!-- Register Moxie tasks -->
|
| | | <taskdef uri="antlib:org.moxie">
|
| | | <classpath location="${moxie.dir}/${moxie.jar}" />
|
| | | </taskdef>
|
| | | |
| | | <!-- Project directories -->
|
| | | <property name="project.src.dir" value="${basedir}/src/main/java" /> |
| | | <property name="project.resources.dir" value="${basedir}/src/main/resources" /> |
| | | <property name="project.distrib.dir" value="${basedir}/src/main/distrib" />
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Scrape the version info from code and setup the build properties |
| | | Initialize Moxie and setup build properties
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildinfo" depends="buildprops">
|
| | | <target name="prepare">
|
| | |
|
| | | <!-- extract Gitblit version number from source code -->
|
| | | <loadfile property="gb.version" srcfile="${basedir}/src/com/gitblit/Constants.java">
|
| | | <filterchain>
|
| | | <linecontains>
|
| | | <contains value="public static final String VERSION = " />
|
| | | </linecontains>
|
| | | <striplinebreaks />
|
| | | <tokenfilter>
|
| | | <replacestring from="public static final String VERSION = "" to="" />
|
| | | <replacestring from="";" to="" />
|
| | | <trim />
|
| | | </tokenfilter>
|
| | | </filterchain>
|
| | | </loadfile>
|
| | |
|
| | | <!-- extract Gitblit version date from source code -->
|
| | | <loadfile property="gb.versionDate" srcfile="${basedir}/src/com/gitblit/Constants.java">
|
| | | <filterchain>
|
| | | <linecontains>
|
| | | <contains value="public static final String VERSION_DATE = " />
|
| | | </linecontains>
|
| | | <striplinebreaks />
|
| | | <tokenfilter>
|
| | | <replacestring from="public static final String VERSION_DATE = "" to="" />
|
| | | <replacestring from="";" to="" />
|
| | | <trim />
|
| | | </tokenfilter>
|
| | | </filterchain>
|
| | | </loadfile>
|
| | | |
| | | <!-- extract JGit version number from source code -->
|
| | | <loadfile property="jgit.version" srcfile="${basedir}/src/com/gitblit/Constants.java">
|
| | | <filterchain>
|
| | | <linecontains>
|
| | | <contains value="public static final String JGIT_VERSION = " />
|
| | | </linecontains>
|
| | | <striplinebreaks />
|
| | | <tokenfilter>
|
| | | <replacestring from="public static final String JGIT_VERSION = "" to="" />
|
| | | <replacestring from="";" to="" />
|
| | | <trim />
|
| | | </tokenfilter>
|
| | | </filterchain>
|
| | | </loadfile> |
| | | <property name="distribution.zipfile" value="gitblit-${gb.version}.zip" />
|
| | | <property name="distribution.warfile" value="gitblit-${gb.version}.war" />
|
| | | <property name="fedclient.zipfile" value="fedclient-${gb.version}.zip" />
|
| | | <property name="manager.zipfile" value="manager-${gb.version}.zip" />
|
| | | <property name="gbapi.zipfile" value="gbapi-${gb.version}.zip" />
|
| | | <property name="express.zipfile" value="express-${gb.version}.zip" />
|
| | | <!-- Setup Ant build from build.moxie and resolve dependencies.
|
| | | if it exists, build.properties is automatically loaded -->
|
| | | <mx:init verbose="no" />
|
| | | |
| | | <!-- Set Ant project properties -->
|
| | | <property name="distribution.zipfile" value="gitblit-${project.version}.zip" />
|
| | | <property name="distribution.tgzfile" value="gitblit-${project.version}.tar.gz" />
|
| | | <property name="distribution.warfile" value="gitblit-${project.version}.war" />
|
| | | <property name="fedclient.zipfile" value="fedclient-${project.version}.zip" />
|
| | | <property name="manager.zipfile" value="manager-${project.version}.zip" />
|
| | | <property name="authority.zipfile" value="authority-${project.version}.zip" />
|
| | | <property name="gbapi.zipfile" value="gbapi-${project.version}.zip" />
|
| | | <property name="express.zipfile" value="express-${project.version}.zip" />
|
| | | |
| | | <!-- Download links -->
|
| | | <property name="gc.url" value="http://code.google.com/p/gitblit/downloads/detail?name=" />
|
| | | </target>
|
| | |
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Cleanup all build artifacts and directories
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="clean" depends="prepare" description="Cleanup all build artifacts and directories">
|
| | | <!-- cleanup legacy build structure -->
|
| | | <!-- this can be eliminated after 1.3.0 release -->
|
| | | <delete>
|
| | | <fileset dir="${basedir}">
|
| | | <include name="*.zip" />
|
| | | <include name="*.war" />
|
| | | <include name="*.jar" />
|
| | | </fileset>
|
| | | </delete>
|
| | | <delete dir="${basedir}/deploy" failonerror="false" />
|
| | | <delete dir="${basedir}/express" failonerror="false" />
|
| | | <delete dir="${basedir}/jar" failonerror="false" />
|
| | | <delete dir="${basedir}/javadoc" failonerror="false" />
|
| | | <delete dir="${basedir}/site" failonerror="false" />
|
| | | <delete dir="${basedir}/temp" failonerror="false" />
|
| | | <delete dir="${basedir}/war" failonerror="false" />
|
| | | |
| | | <!-- Clean build and target directories -->
|
| | | <mx:clean />
|
| | |
|
| | | </target>
|
| | |
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Setup
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="setup" depends="prepare" description="Setup up project">
|
| | |
|
| | | <!-- copy distrib/data to project data directory -->
|
| | | <mkdir dir="${basedir}/data" />
|
| | | <copy todir="${basedir}/data" overwrite="false">
|
| | | <fileset dir="${project.distrib.dir}/data" />
|
| | | </copy>
|
| | | |
| | | <!-- copy gitblit.properties to the source directory.
|
| | | this file is only used for parsing setting descriptions. -->
|
| | | <copy tofile="${project.src.dir}/reference.properties" overwrite="true"
|
| | | file="${project.distrib.dir}/data/gitblit.properties" />
|
| | | |
| | | <!-- |
| | | upgrade existing workspace to data directory
|
| | | this code can be eliminated after 1.3.0 release
|
| | | -->
|
| | | <move todir="${basedir}/data" overwrite="true" failonerror="false">
|
| | | <fileset dir="${basedir}">
|
| | | <include name="users.conf" />
|
| | | <include name="projects.conf" />
|
| | | <include name="gitblit.properties" />
|
| | | <include name="serverKeyStore.jks" />
|
| | | <include name="serverTrustStore.jks" />
|
| | | </fileset>
|
| | | </move>
|
| | | <move todir="${basedir}/data/certs" overwrite="true" failonerror="false">
|
| | | <fileset dir="${basedir}/certs" />
|
| | | </move>
|
| | | <move todir="${basedir}/data/git" overwrite="true" failonerror="false">
|
| | | <fileset dir="${basedir}/git" />
|
| | | </move>
|
| | | <move todir="${basedir}/data/proposals" overwrite="true" failonerror="false">
|
| | | <fileset dir="${basedir}/proposals" />
|
| | | </move>
|
| | | </target>
|
| | |
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Compile
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="compile" depends="buildinfo" description="Retrieves dependencies and compiles Gitblit from source">
|
| | | <target name="compile" depends="setup" description="compiles Gitblit from source">
|
| | | |
| | | <!-- Generate the Keys class from the properties file -->
|
| | | <mx:keys propertiesfile="${project.distrib.dir}/data/gitblit.properties"
|
| | | outputclass="com.gitblit.Keys"
|
| | | todir="${project.src.dir}" />
|
| | |
|
| | | <!-- copy required distribution files to project folder -->
|
| | | <copy todir="${basedir}" overwrite="false">
|
| | | <fileset dir="${basedir}/distrib">
|
| | | <include name="gitblit.properties" />
|
| | | <include name="users.conf" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- copy gitblit.properties to the WEB-INF folder.
|
| | | this file is only used for parsing setting descriptions. -->
|
| | | <copy tofile="${basedir}/src/WEB-INF/reference.properties" overwrite="true"
|
| | | file="${basedir}/distrib/gitblit.properties" />
|
| | |
|
| | | <!-- Compile the build tool and execute it.
|
| | | This downloads missing compile-time dependencies from Maven. -->
|
| | |
|
| | | <delete dir="${project.build.dir}" />
|
| | | <mkdir dir="${project.build.dir}" />
|
| | | <javac debug="true" srcdir="${basedir}/src" destdir="${project.build.dir}">
|
| | | <include name="com/gitblit/build/Build.java" /> |
| | | <include name="com/gitblit/Constants.java" />
|
| | | <include name="com/gitblit/utils/StringUtils.java" /> |
| | | </javac>
|
| | | <java classpath="${project.build.dir}" classname="com.gitblit.build.Build" />
|
| | |
|
| | | <!-- Compile Project -->
|
| | | <path id="master-classpath">
|
| | | <fileset dir="${basedir}/ext">
|
| | | <include name="*.jar" />
|
| | | </fileset>
|
| | | <pathelement path="${project.build.dir}" /> |
| | | </path>
|
| | | <javac debug="true" destdir="${project.build.dir}" failonerror="false">
|
| | | <src path="${basedir}/src" />
|
| | | <classpath refid="master-classpath" />
|
| | | </javac>
|
| | | <copy todir="${project.build.dir}">
|
| | | <fileset dir="${basedir}/src" excludes="**/*.java,**/thumbs.db" />
|
| | | </copy>
|
| | | <!-- Compile project incrementally -->
|
| | | <mx:javac scope="compile" clean="false" />
|
| | | |
| | | </target>
|
| | |
|
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Report the compile dependencies on the console
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="report" depends="prepare" description="generate dependency report">
|
| | | |
| | | <!-- Report compile dependencies to the console -->
|
| | | <mx:report scope="compile" destfile="${project.targetDirectory}/dependencies.txt" />
|
| | | |
| | | </target>
|
| | |
|
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Test
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="test" depends="compile" description="compiles Gitblit from source and runs unit tests">
|
| | | |
| | | <!-- Compile unit tests -->
|
| | | <mx:javac scope="test" />
|
| | | |
| | | <!-- Run unit tests -->
|
| | | <mx:test failonerror="true" />
|
| | | |
| | | </target>
|
| | |
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Run Gitblit GO
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="run" depends="compile" description="Run Gitblit GO">
|
| | | |
| | | <!-- run the mainclass in a separate JVM -->
|
| | | <mx:run fork="true" />
|
| | | |
| | | </target> |
| | | |
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | |
| | | -->
|
| | | <target name="buildGO" depends="compile" description="Build Gitblit GO distribution">
|
| | |
|
| | | <echo>Building Gitblit GO ${gb.version}</echo>
|
| | | <echo>Building Gitblit GO ${project.version}</echo>
|
| | |
|
| | | <!-- Delete the deploy folder -->
|
| | | <delete dir="${project.deploy.dir}" />
|
| | | <local name="go.dir" />
|
| | | <property name="go.dir" value="${project.outputDirectory}/go" /> |
| | | <delete dir="${go.dir}" />
|
| | |
|
| | | <!-- Create deployment folder structure -->
|
| | | <mkdir dir="${project.deploy.dir}" />
|
| | | <copy todir="${project.deploy.dir}">
|
| | | <fileset dir="${basedir}/distrib">
|
| | | <include name="**/*" />
|
| | | <exclude name="federation.properties" />
|
| | | <exclude name="openshift.mkd" />
|
| | | </fileset>
|
| | | <fileset dir="${basedir}">
|
| | | <prepareDataDirectory toDir="${go.dir}/data" />
|
| | | |
| | | <!-- Build jar -->
|
| | | <mx:jar destfile="${go.dir}/gitblit.jar" includeresources="true">
|
| | | <mainclass name="com.gitblit.GitBlitServer" />
|
| | | <launcher paths="ext" />
|
| | | </mx:jar>
|
| | |
|
| | | <!-- Generate the docs for the GO build -->
|
| | | <generateDocs toDir="${go.dir}/docs" />
|
| | | |
| | | <!-- Create GO Windows Zip deployment -->
|
| | | <mx:zip basedir="${go.dir}">
|
| | | <!-- LICENSE and NOTICE -->
|
| | | <fileset dir="${basedir}" >
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | </copy>
|
| | | <!-- Windows distrib files -->
|
| | | <zipfileset dir="${project.distrib.dir}/win" />
|
| | | <!-- Gitblit Authority data -->
|
| | | <zipfileset dir="${project.distrib.dir}/data/certs" prefix="data/certs" />
|
| | | <!-- include all dependencies -->
|
| | | <dependencies prefix="ext" />
|
| | | </mx:zip>
|
| | |
|
| | | <!-- Build jar -->
|
| | | <jar jarfile="${project.deploy.dir}/${project.jar}">
|
| | | <fileset dir="${project.build.dir}">
|
| | | <include name="**/*" />
|
| | | <exclude name="com/gitblit/client/**" />
|
| | | <!-- Create GO Linux/OSX tar.gz deployment -->
|
| | | <mx:tar basedir="${go.dir}" longfile="gnu" compression="gzip">
|
| | | <!-- LICENSE and NOTICE -->
|
| | | <fileset dir="${basedir}" >
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | <fileset dir="${project.resources.dir}">
|
| | | <exclude name="thumbs.db" />
|
| | | </fileset>
|
| | | <manifest>
|
| | | <attribute name="Main-Class" value="${project.mainclass}" />
|
| | | </manifest>
|
| | | </jar>
|
| | |
|
| | | <!-- Build the docs for the deploy -->
|
| | | <antcall target="buildDocs" inheritall="true" inheritrefs="true">
|
| | | <param name="docs.output.dir" value="${project.deploy.dir}/docs" />
|
| | | </antcall>
|
| | | |
| | | <!-- Create Zip deployment --> |
| | | <zip destfile="${distribution.zipfile}">
|
| | | <fileset dir="${project.deploy.dir}">
|
| | | <include name="**/*" />
|
| | | </fileset>
|
| | | </zip>
|
| | | <!-- Linux/OSX distrib files -->
|
| | | <tarfileset dir="${project.distrib.dir}/linux" filemode="755" />
|
| | | <!-- Gitblit Authority data -->
|
| | | <zipfileset dir="${project.distrib.dir}/data/certs" prefix="data/certs" />
|
| | | <!-- include all dependencies -->
|
| | | <dependencies prefix="ext" />
|
| | | </mx:tar> |
| | |
|
| | | </target>
|
| | |
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Build Gitblit Docs which are bundled with GO and WAR downloads
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildDocs">
|
| | | <!-- Build Docs -->
|
| | | <mkdir dir="${docs.output.dir}" />
|
| | | <copy todir="${docs.output.dir}">
|
| | | <!-- Copy selected Gitblit resources -->
|
| | | <fileset dir="${project.resources.dir}">
|
| | | <include name="bootstrap.140.css" />
|
| | | <include name="bootstrap.gb.css" />
|
| | | <include name="markdown.css" />
|
| | | <include name="gitblt_25_white.png" />
|
| | | <include name="gitblt-favicon.png" />
|
| | | <include name="lock_go_16x16.png" />
|
| | | <include name="lock_pull_16x16.png" />
|
| | | <include name="shield_16x16.png" />
|
| | | <include name="cold_16x16.png" />
|
| | | <include name="bug_16x16.png" />
|
| | | <include name="book_16x16.png" />
|
| | | <include name="blank.png" />
|
| | | <include name="federated_16x16.png" />
|
| | | <include name="arrow_page.png" />
|
| | | </fileset>
|
| | |
|
| | | <!-- Copy Doc images -->
|
| | | <fileset dir="${basedir}/docs">
|
| | | <include name="*.png" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Copy google-code-prettify -->
|
| | | <mkdir dir="${docs.output.dir}/prettify" />
|
| | | <copy todir="${docs.output.dir}/prettify">
|
| | | <fileset dir="${basedir}/src/com/gitblit/wicket/pages/prettify">
|
| | | <exclude name="thumbs.db" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Build deployment doc pages -->
|
| | | <java classpath="${project.build.dir}" classname="com.gitblit.build.BuildSite">
|
| | | <classpath refid="master-classpath" />
|
| | | <arg value="--sourceFolder" />
|
| | | <arg value="${basedir}/docs" />
|
| | |
|
| | | <arg value="--outputFolder" />
|
| | | <arg value="${docs.output.dir}" />
|
| | |
|
| | | <arg value="--pageHeader" />
|
| | | <arg value="${basedir}/docs/doc_header.html" />
|
| | |
|
| | | <arg value="--pageFooter" />
|
| | | <arg value="${basedir}/docs/doc_footer.html" />
|
| | |
|
| | | <arg value="--skip" />
|
| | | <arg value="screenshots" />
|
| | |
|
| | | <arg value="--skip" />
|
| | | <arg value="releases" />
|
| | |
|
| | | <arg value="--alias" />
|
| | | <arg value="index=overview" />
|
| | |
|
| | | <arg value="--alias" />
|
| | | <arg value="properties=settings" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%VERSION%=${gb.version}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%GO%=${distribution.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%WAR%=${distribution.warfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%FEDCLIENT%=${fedclient.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%MANAGER%=${manager.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%API%=${gbapi.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%EXPRESS%=${express.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%BUILDDATE%=${gb.versionDate}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%JGIT%=${jgit.version}" />
|
| | |
|
| | | <arg value="--properties" />
|
| | | <arg value="%PROPERTIES%=${basedir}/distrib/gitblit.properties" />
|
| | |
|
| | | <arg value="--nomarkdown" />
|
| | | <arg value="%BEGINCODE%:%ENDCODE%" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value=""%BEGINCODE%=<pre class='prettyprint lang-java'>"" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%ENDCODE%=</pre>" />
|
| | | |
| | | <arg value="--regex" />
|
| | | <arg value=""\b(issue)(\s*[#]?|-){0,1}(\d+)\b!!!<a href='http://code.google.com/p/gitblit/issues/detail?id=$3'>issue $3</a>"" />
|
| | | |
| | | </java>
|
| | | </target>
|
| | | |
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Build Gitblit WAR
|
| | |
| | | -->
|
| | | <target name="buildWAR" depends="compile" description="Build Gitblit WAR">
|
| | |
|
| | | <echo>Building Gitblit WAR ${gb.version}</echo>
|
| | | |
| | | <delete dir="${project.war.dir}" />
|
| | | <echo>Building Gitblit WAR ${project.version}</echo>
|
| | |
|
| | | <!-- Copy web.xml and users.conf to WEB-INF -->
|
| | | <copy todir="${project.war.dir}/WEB-INF">
|
| | | <fileset dir="${basedir}/distrib">
|
| | | <include name="users.conf" />
|
| | | </fileset>
|
| | | <fileset dir="${basedir}/src/WEB-INF">
|
| | | <include name="web.xml" />
|
| | | </fileset>
|
| | | <fileset dir="${basedir}">
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | </copy>
|
| | | <local name="war.dir" />
|
| | | <property name="war.dir" value="${project.outputDirectory}/war" />
|
| | | <delete dir="${war.dir}" />
|
| | |
|
| | | <!-- Copy gitblit.properties as reference.properties -->
|
| | | <copy tofile="${project.war.dir}/WEB-INF/reference.properties" |
| | | file="${basedir}/distrib/gitblit.properties"/>
|
| | | |
| | | <!-- Build the docs for the WAR build -->
|
| | | <antcall target="buildDocs" inheritall="true" inheritrefs="true">
|
| | | <param name="docs.output.dir" value="${project.war.dir}/WEB-INF/docs" />
|
| | | </antcall>
|
| | | |
| | | <!-- Build the WAR web.xml from the prototype web.xml and gitblit.properties --> |
| | | <java classpath="${project.build.dir}" classname="com.gitblit.build.BuildWebXml">
|
| | | <classpath refid="master-classpath" />
|
| | | |
| | | <arg value="--sourceFile" />
|
| | | <arg value="${basedir}/src/WEB-INF/web.xml" />
|
| | | |
| | | <arg value="--destinationFile" />
|
| | | <arg value="${project.war.dir}/WEB-INF/web.xml" />
|
| | | |
| | | <arg value="--propertiesFile" />
|
| | | <arg value="${basedir}/distrib/gitblit.properties" />
|
| | | </java>
|
| | | <local name="webinf" />
|
| | | <property name="webinf" value="${war.dir}/WEB-INF" />
|
| | |
|
| | | <!-- Gitblit resources -->
|
| | | <copy todir="${project.war.dir}">
|
| | | <fileset dir="${project.resources.dir}">
|
| | | <exclude name="thumbs.db" />
|
| | | </fileset>
|
| | | </copy>
|
| | | |
| | | <!-- Gitblit library dependencies -->
|
| | | <mkdir dir="${project.war.dir}/WEB-INF/lib"/>
|
| | | <copy todir="${project.war.dir}/WEB-INF/lib">
|
| | | <fileset dir="${basedir}/ext">
|
| | | <exclude name="*-sources.jar" />
|
| | | <exclude name="*-javadoc.jar" />
|
| | | <exclude name="jcommander*.jar" />
|
| | | <exclude name="jetty*.jar" />
|
| | | <exclude name="junit*.jar" />
|
| | | <exclude name="servlet*.jar" />
|
| | | </fileset>
|
| | | </copy>
|
| | | <!-- Generate the docs for the WAR build -->
|
| | | <generateDocs toDir="${webinf}/docs" />
|
| | |
|
| | | <!-- Gitblit classes -->
|
| | | <mkdir dir="${project.war.dir}/WEB-INF/classes"/>
|
| | | <copy todir="${project.war.dir}/WEB-INF/classes">
|
| | | <fileset dir="${project.build.dir}">
|
| | | <exclude name="WEB-INF/" />
|
| | | <exclude name="com/gitblit/tests/" />
|
| | | <exclude name="com/gitblit/build/**" />
|
| | | <exclude name="com/gitblit/client/**" />
|
| | | <exclude name="com/gitblit/GitBlitServer*.class" />
|
| | | <exclude name="com/gitblit/Launcher*.class" />
|
| | | <exclude name="com/gitblit/MakeCertificate*.class" />
|
| | | </fileset>
|
| | | </copy>
|
| | | <!-- Prepare the data directory -->
|
| | | <prepareDataDirectory toDir="${webinf}/data" />
|
| | |
|
| | | <!-- Build the WAR web.xml from the prototype web.xml -->
|
| | | <mx:webxml sourcefile="${project.src.dir}/WEB-INF/web.xml" destfile="${webinf}/web.xml" />
|
| | |
|
| | | <!-- Gitblit jar -->
|
| | | <mx:genjar destfile="${webinf}/lib/gitblit.jar" includeresources="false" excludeclasspathjars="true">
|
| | | <!-- Specify all web.xml servlets and filters -->
|
| | | <class name="com.gitblit.GitBlit" />
|
| | | <class name="com.gitblit.DownloadZipFilter" />
|
| | | <class name="com.gitblit.DownloadZipServlet" />
|
| | | <class name="com.gitblit.EnforceAuthenticationFilter" />
|
| | | <class name="com.gitblit.FederationServlet" />
|
| | | <class name="com.gitblit.GitFilter" />
|
| | | <class name="com.gitblit.GitServlet" />
|
| | | <class name="com.gitblit.PagesFilter" />
|
| | | <class name="com.gitblit.PagesServlet" />
|
| | | <class name="com.gitblit.RobotsTxtServlet" />
|
| | | <class name="com.gitblit.RpcFilter" />
|
| | | <class name="com.gitblit.RpcServlet" />
|
| | | <class name="com.gitblit.SyndicationFilter" />
|
| | | <class name="com.gitblit.SyndicationServlet" />
|
| | | <class name="com.gitblit.wicket.GitBlitWebApp" />
|
| | | </mx:genjar>
|
| | |
|
| | | <!-- Build the WAR file -->
|
| | | <jar basedir="${project.war.dir}" destfile="${distribution.warfile}" compress="true" />
|
| | | <mx:zip basedir="${war.dir}" destfile="${project.targetDirectory}/${distribution.warfile}" compress="true" >
|
| | | <!-- Resources in root -->
|
| | | <fileset dir="${project.resources.dir}">
|
| | | <exclude name="thumbs.db" />
|
| | | <exclude name="*.mkd" />
|
| | | </fileset>
|
| | | <!-- WEB-INF directory -->
|
| | | <zipfileset prefix="WEB-INF" dir="${basedir}" >
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </zipfileset>
|
| | | <zipfileset prefix="WEB-INF" file="${project.compileOutputDirectory}/WEB-INF/weblogic.xml" />
|
| | | <!-- include "war" tagged dependencies -->
|
| | | <dependencies prefix="WEB-INF/lib" tag="war" />
|
| | | </mx:zip>
|
| | | </target>
|
| | |
|
| | | |
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Build the stand-alone, command-line Gitblit Federation Client
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildFederationClient" depends="compile" description="Builds the stand-alone Gitblit federation client">
|
| | | <echo>Building Gitblit Federation Client ${gb.version}</echo>
|
| | | <echo>Building Gitblit Federation Client ${project.version}</echo>
|
| | |
|
| | | <genjar jarfile="fedclient.jar">
|
| | | <class name="com.gitblit.FederationClientLauncher" />
|
| | | <resource file="${project.build.dir}/log4j.properties" />
|
| | | <classfilter>
|
| | | <exclude name="org.apache." />
|
| | | <exclude name="org.bouncycastle." />
|
| | | <exclude name="org.eclipse." />
|
| | | <exclude name="org.slf4j." />
|
| | | <exclude name="com.beust." />
|
| | | <exclude name="com.google." />
|
| | | </classfilter>
|
| | | <classpath refid="master-classpath" />
|
| | | <manifest>
|
| | | <attribute name="Main-Class" value="com.gitblit.FederationClientLauncher" />
|
| | | <attribute name="Specification-Version" value="${gb.version}" />
|
| | | <attribute name="Release-Date" value="${gb.versionDate}" />
|
| | | </manifest>
|
| | | </genjar>
|
| | | <!-- generate jar by traversing the class hierarchy of the specified
|
| | | classes, exclude any classes in classpath jars -->
|
| | | <mx:genjar tag="" includeresources="false" excludeClasspathJars="true"
|
| | | destfile="${project.targetDirectory}/fedclient.jar">
|
| | | <mainclass name="com.gitblit.FederationClient" />
|
| | | <launcher paths="ext" />
|
| | | <resource file="${project.compileOutputDirectory}/log4j.properties" />
|
| | | </mx:genjar>
|
| | |
|
| | | <!-- Build the federation client zip file -->
|
| | | <zip destfile="${fedclient.zipfile}">
|
| | | <mx:zip destfile="${project.targetDirectory}/${fedclient.zipfile}">
|
| | | <fileset dir="${basedir}">
|
| | | <include name="fedclient.jar" />
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | <fileset dir="${basedir}/distrib">
|
| | | <fileset dir="${project.targetDirectory}">
|
| | | <include name="fedclient.jar" />
|
| | | </fileset>
|
| | | <fileset dir="${project.distrib.dir}">
|
| | | <include name="federation.properties" />
|
| | | </fileset>
|
| | | </zip>
|
| | | <!-- include "fedclient" tagged dependencies -->
|
| | | <dependencies prefix="ext" tag="fedclient" />
|
| | | </mx:zip>
|
| | | |
| | | <!-- Cleanup -->
|
| | | <delete file="${project.targetDirectory}/fedclient.jar" />
|
| | | |
| | | </target>
|
| | |
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Build a Gitblit filesystem for deployment to RedHat OpenShif Expresst
|
| | | Build a Gitblit filesystem for deployment to RedHat OpenShift Express
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildOpenShift" depends="compile" description="Build exploded WAR file suitable for deployment to OpenShift Express">
|
| | | <echo>Building Gitblit Express for RedHat OpenShift ${gb.version}</echo>
|
| | | <target name="buildExpress" depends="compile" description="Build exploded WAR file suitable for deployment to OpenShift Express">
|
| | | <echo>Building Gitblit Express for RedHat OpenShift ${project.version}</echo>
|
| | |
|
| | | <delete dir="${project.express.dir}" />
|
| | | <local name="express.dir" />
|
| | | <property name="express.dir" value="${project.outputDirectory}/express" /> |
| | | <delete dir="${express.dir}" />
|
| | |
|
| | | <!-- Create the OpenShift filesystem -->
|
| | | <property name="deployments.root" value="${project.express.dir}/deployments/ROOT.war"/>
|
| | | <local name="deployments.root" />
|
| | | <property name="deployments.root" value="${express.dir}/deployments/ROOT.war"/>
|
| | | <mkdir dir="${deployments.root}" />
|
| | | <touch file="${project.express.dir}/deployments/ROOT.war.dodeploy" />
|
| | | <touch file="${express.dir}/deployments/ROOT.war.dodeploy" />
|
| | |
|
| | | <!-- Copy the Gitblit OpenShift readme file -->
|
| | | <copy tofile="${project.express.dir}/README.gitblit" |
| | | file="${basedir}/distrib/openshift.mkd"/>
|
| | | <local name="webinf" />
|
| | | <property name="webinf" value="${deployments.root}/WEB-INF" />
|
| | |
|
| | | <!-- Copy LICENSE and NOTICE to WEB-INF -->
|
| | | <copy todir="${deployments.root}/WEB-INF">
|
| | | <!-- Prepare the data directory -->
|
| | | <prepareDataDirectory toDir="${webinf}/data" />
|
| | | |
| | | <!-- Build the Express web.xml from the prototype web.xml and gitblit.properties -->
|
| | | <!-- THIS FILE IS NOT OVERRIDDEN ONCE IT IS BUILT!!! -->
|
| | | <mx:webxml sourcefile="${project.src.dir}/WEB-INF/web.xml" destfile="${webinf}/web.xml"
|
| | | propertiesFile="${project.distrib.dir}/data/gitblit.properties"
|
| | | skip="server.*" />
|
| | |
|
| | | <!-- Gitblit classes -->
|
| | | <mx:genjar destfile="${webinf}/lib/gitblit.jar" includeresources="false" excludeclasspathjars="true">
|
| | | <!-- Specify all web.xml servlets and filters -->
|
| | | <class name="com.gitblit.GitBlit" />
|
| | | <class name="com.gitblit.DownloadZipFilter" />
|
| | | <class name="com.gitblit.DownloadZipServlet" />
|
| | | <class name="com.gitblit.EnforceAuthenticationFilter" />
|
| | | <class name="com.gitblit.FederationServlet" />
|
| | | <class name="com.gitblit.GitFilter" />
|
| | | <class name="com.gitblit.GitServlet" />
|
| | | <class name="com.gitblit.PagesFilter" />
|
| | | <class name="com.gitblit.PagesServlet" />
|
| | | <class name="com.gitblit.RobotsTxtServlet" />
|
| | | <class name="com.gitblit.RpcFilter" />
|
| | | <class name="com.gitblit.RpcServlet" />
|
| | | <class name="com.gitblit.SyndicationFilter" />
|
| | | <class name="com.gitblit.SyndicationServlet" />
|
| | | <class name="com.gitblit.wicket.GitBlitWebApp" />
|
| | | </mx:genjar>
|
| | |
|
| | | <!-- Build Express Zip file -->
|
| | | <mx:zip basedir="${express.dir}" destfile="${project.targetDirectory}/${express.zipfile}">
|
| | | <fileset dir="${basedir}">
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Copy gitblit.properties as reference.properties -->
|
| | | <copy tofile="${deployments.root}/WEB-INF/reference.properties" |
| | | file="${basedir}/distrib/gitblit.properties"/>
|
| | |
|
| | | <!-- Build the WAR web.xml from the prototype web.xml and gitblit.properties -->
|
| | | <!-- THIS FILE IS NOT OVERRIDDEN ONCE IT IS BUILT!!! -->
|
| | | <java classpath="${project.build.dir}" classname="com.gitblit.build.BuildWebXml">
|
| | | <classpath refid="master-classpath" />
|
| | |
|
| | | <arg value="--sourceFile" />
|
| | | <arg value="${basedir}/src/WEB-INF/web.xml" />
|
| | |
|
| | | <arg value="--destinationFile" />
|
| | | <arg value="${deployments.root}/WEB-INF/web.xml" />
|
| | |
|
| | | <arg value="--propertiesFile" />
|
| | | <arg value="${basedir}/distrib/gitblit.properties" />
|
| | | </java>
|
| | |
|
| | | <!-- Gitblit resources -->
|
| | | <copy todir="${deployments.root}">
|
| | | <fileset dir="${project.resources.dir}">
|
| | | <!-- README -->
|
| | | <zipfileset fullpath="README.gitblit" file="${project.siteSourceDirectory}/openshift.mkd" />
|
| | | <!-- resources -->
|
| | | <zipfileset prefix="deployments/ROOT.war" dir="${project.resources.dir}">
|
| | | <exclude name="thumbs.db" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Gitblit library dependencies -->
|
| | | <mkdir dir="${deployments.root}/WEB-INF/lib"/>
|
| | | <copy todir="${deployments.root}/WEB-INF/lib">
|
| | | <fileset dir="${basedir}/ext">
|
| | | <exclude name="*-sources.jar" />
|
| | | <exclude name="*-javadoc.jar" />
|
| | | <exclude name="jcommander*.jar" />
|
| | | <exclude name="jetty*.jar" />
|
| | | <exclude name="junit*.jar" />
|
| | | <exclude name="servlet*.jar" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Gitblit classes -->
|
| | | <mkdir dir="${deployments.root}/WEB-INF/classes"/>
|
| | | <copy todir="${deployments.root}/WEB-INF/classes">
|
| | | <fileset dir="${project.build.dir}">
|
| | | <exclude name="WEB-INF/" />
|
| | | <exclude name="com/gitblit/tests/" />
|
| | | <exclude name="com/gitblit/build/**" />
|
| | | <exclude name="com/gitblit/client/**" />
|
| | | <exclude name="com/gitblit/GitBlitServer*.class" />
|
| | | <exclude name="com/gitblit/Launcher*.class" />
|
| | | <exclude name="com/gitblit/MakeCertificate*.class" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Build Express Zip file -->
|
| | | <zip destfile="${express.zipfile}">
|
| | | <fileset dir="${project.express.dir}" />
|
| | | </zip>
|
| | | <exclude name="*.mkd" />
|
| | | </zipfileset>
|
| | | <!-- include "war" tagged dependencies -->
|
| | | <dependencies prefix="deployments/ROOT.war/WEB-INF/lib" tag="war" />
|
| | | </mx:zip>
|
| | |
|
| | | </target>
|
| | |
|
| | |
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildManager" depends="compile" description="Builds the stand-alone Gitblit Manager">
|
| | | <echo>Building Gitblit Manager ${gb.version}</echo>
|
| | | <echo>Building Gitblit Manager ${project.version}</echo>
|
| | |
|
| | | <genjar jarfile="manager-${gb.version}.jar">
|
| | | <resource file="${basedir}/src/com/gitblit/client/splash.png" />
|
| | | <resource file="${basedir}/resources/gitblt-favicon.png" />
|
| | | <resource file="${basedir}/resources/gitweb-favicon.png" />
|
| | | <resource file="${basedir}/resources/user_16x16.png" />
|
| | | <resource file="${basedir}/resources/settings_16x16.png" />
|
| | | <resource file="${basedir}/resources/lock_go_16x16.png" />
|
| | | <resource file="${basedir}/resources/lock_pull_16x16.png" />
|
| | | <resource file="${basedir}/resources/shield_16x16.png" />
|
| | | <resource file="${basedir}/resources/federated_16x16.png" />
|
| | | <resource file="${basedir}/resources/cold_16x16.png" />
|
| | | <resource file="${basedir}/resources/book_16x16.png" />
|
| | | <resource file="${basedir}/resources/bug_16x16.png" />
|
| | | <resource file="${basedir}/resources/health_16x16.png" />
|
| | | <resource file="${basedir}/resources/feed_16x16.png" />
|
| | | <resource file="${basedir}/resources/bullet_feed.png" />
|
| | | <resource file="${basedir}/resources/search-icon.png" />
|
| | | <resource file="${basedir}/resources/commit_changes_16x16.png" />
|
| | | <resource file="${basedir}/resources/commit_merge_16x16.png" />
|
| | | <resource file="${basedir}/resources/blank.png" />
|
| | | <resource file="${basedir}/src/com/gitblit/wicket/GitBlitWebApp.properties" />
|
| | | <!-- generate jar by traversing the class hierarchy of the specified
|
| | | classes, exclude any classes in classpath jars -->
|
| | | <mx:genjar tag="" includeResources="false" excludeClasspathJars="true"
|
| | | destfile="${project.targetDirectory}/manager.jar">
|
| | | <resource file="${project.src.dir}/com/gitblit/client/splash.png" />
|
| | | <resource file="${project.resources.dir}/gitblt-favicon.png" />
|
| | | <resource file="${project.resources.dir}/gitweb-favicon.png" />
|
| | | <resource file="${project.resources.dir}/git-orange-16x16.png" />
|
| | | <resource file="${project.resources.dir}/user_16x16.png" />
|
| | | <resource file="${project.resources.dir}/users_16x16.png" />
|
| | | <resource file="${project.resources.dir}/settings_16x16.png" />
|
| | | <resource file="${project.resources.dir}/lock_go_16x16.png" />
|
| | | <resource file="${project.resources.dir}/lock_pull_16x16.png" />
|
| | | <resource file="${project.resources.dir}/shield_16x16.png" />
|
| | | <resource file="${project.resources.dir}/federated_16x16.png" />
|
| | | <resource file="${project.resources.dir}/cold_16x16.png" />
|
| | | <resource file="${project.resources.dir}/book_16x16.png" />
|
| | | <resource file="${project.resources.dir}/bug_16x16.png" />
|
| | | <resource file="${project.resources.dir}/health_16x16.png" />
|
| | | <resource file="${project.resources.dir}/feed_16x16.png" />
|
| | | <resource file="${project.resources.dir}/bullet_feed.png" />
|
| | | <resource file="${project.resources.dir}/search-icon.png" />
|
| | | <resource file="${project.resources.dir}/commit_changes_16x16.png" />
|
| | | <resource file="${project.resources.dir}/commit_merge_16x16.png" />
|
| | | <resource file="${project.resources.dir}/commit_divide_16x16.png" />
|
| | | <resource file="${project.resources.dir}/star_16x16.png" />
|
| | | <resource file="${project.resources.dir}/blank.png" />
|
| | | <resource file="${project.src.dir}/log4j.properties" />
|
| | | <resource>
|
| | | <!-- inlcude all translations -->
|
| | | <fileset dir="${project.src.dir}/com/gitblit/wicket">
|
| | | <include name="*.properties" />
|
| | | </fileset>
|
| | | </resource>
|
| | |
|
| | | <class name="com.gitblit.client.GitblitManagerLauncher" />
|
| | | <classfilter>
|
| | | <exclude name="org.apache." />
|
| | | <exclude name="org.bouncycastle." />
|
| | | <exclude name="org.eclipse." />
|
| | | <exclude name="org.slf4j." />
|
| | | <exclude name="com.beust." />
|
| | | <exclude name="com.google." />
|
| | | </classfilter>
|
| | | <classpath refid="master-classpath" />
|
| | | <mainclass name="com.gitblit.client.GitblitManagerLauncher" />
|
| | | <manifest>
|
| | | <attribute name="Main-Class" value="com.gitblit.client.GitblitManagerLauncher" />
|
| | | <attribute name="SplashScreen-Image" value="splash.png" />
|
| | | <attribute name="Specification-Version" value="${gb.version}" />
|
| | | <attribute name="Release-Date" value="${gb.versionDate}" />
|
| | | </manifest>
|
| | | </genjar>
|
| | | </mx:genjar>
|
| | |
|
| | | <!-- Build Manager Zip file -->
|
| | | <zip destfile="${manager.zipfile}">
|
| | | <mx:zip destfile="${project.targetDirectory}/${manager.zipfile}">
|
| | | <fileset dir="${basedir}">
|
| | | <include name="manager-${gb.version}.jar" />
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | </zip>
|
| | | <fileset dir="${project.targetDirectory}">
|
| | | <include name="manager.jar" />
|
| | | </fileset>
|
| | | <!-- include "manager" tagged dependencies -->
|
| | | <dependencies prefix="ext" tag="manager" />
|
| | | </mx:zip>
|
| | | |
| | | <!-- Cleanup -->
|
| | | <delete file="${project.targetDirectory}/manager.jar" />
|
| | | </target>
|
| | |
|
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Build the Gitblit API client library
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildApiLibrary" depends="compile" description="Builds the Gitblit RPC client library">
|
| | | <echo>Building Gitblit API Library ${gb.version}</echo>
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Build the stand-alone, Gitblit Authority
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildAuthority" depends="compile" description="Builds the stand-alone Gitblit Authority">
|
| | | <echo>Building Gitblit Authority ${project.version}</echo>
|
| | |
|
| | | <!-- generate jar by traversing the class hierarchy of the specified
|
| | | classes, exclude any classes in "authority" classpath jars -->
|
| | | <mx:genjar tag="authority" excludeClasspathJars="true" |
| | | destfile="${project.targetDirectory}/authority.jar">
|
| | | <resource file="${project.src.dir}/com/gitblit/client/splash.png" />
|
| | | <resource file="${project.resources.dir}/gitblt-favicon.png" />
|
| | | <resource file="${project.resources.dir}/user_16x16.png" />
|
| | | <resource file="${project.resources.dir}/users_16x16.png" />
|
| | | <resource file="${project.resources.dir}/rosette_16x16.png" />
|
| | | <resource file="${project.resources.dir}/rosette_32x32.png" />
|
| | | <resource file="${project.resources.dir}/vcard_16x16.png" />
|
| | | <resource file="${project.resources.dir}/settings_16x16.png" />
|
| | | <resource file="${project.resources.dir}/settings_32x32.png" />
|
| | | <resource file="${project.resources.dir}/search-icon.png" />
|
| | | <resource file="${project.resources.dir}/mail_16x16.png" />
|
| | | <resource file="${project.resources.dir}/script_16x16.png" />
|
| | | <resource file="${project.resources.dir}/blank.png" />
|
| | | <resource file="${project.resources.dir}/bullet_green.png" />
|
| | | <resource file="${project.resources.dir}/bullet_orange.png" />
|
| | | <resource file="${project.resources.dir}/bullet_red.png" />
|
| | | <resource file="${project.resources.dir}/bullet_white.png" />
|
| | | <resource file="${project.resources.dir}/bullet_delete.png" />
|
| | | <resource file="${project.resources.dir}/bullet_key.png" />
|
| | | <resource file="${project.src.dir}/log4j.properties" />
|
| | | <resource>
|
| | | <!-- inlcude all translations -->
|
| | | <fileset dir="${project.src.dir}/com/gitblit/wicket">
|
| | | <include name="*.properties" />
|
| | | </fileset>
|
| | | </resource>
|
| | |
|
| | | <mainclass name="com.gitblit.authority.Launcher" />
|
| | | <manifest>
|
| | | <attribute name="SplashScreen-Image" value="splash.png" />
|
| | | </manifest>
|
| | | </mx:genjar>
|
| | |
|
| | | <!-- Build Authority Zip file -->
|
| | | <mx:zip destfile="${project.targetDirectory}/${authority.zipfile}">
|
| | | <fileset dir="${basedir}">
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | <fileset dir="${project.targetDirectory}">
|
| | | <include name="authority.jar" />
|
| | | </fileset>
|
| | | <zipfileset dir="${project.distrib.dir}/data" prefix="data">
|
| | | <include name="users.conf" />
|
| | | <include name="gitblit.properties" />
|
| | | </zipfileset>
|
| | | <!-- Gitblit Authority data -->
|
| | | <zipfileset dir="${project.distrib.dir}/data/certs" prefix="data/certs" />
|
| | | <!-- include "authority" tagged dependencies -->
|
| | | <dependencies prefix="ext" tag="authority" />
|
| | | </mx:zip>
|
| | | |
| | | <!-- Cleanup -->
|
| | | <delete file="${project.targetDirectory}/authority.jar" />
|
| | | </target>
|
| | | |
| | | <!-- |
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Build the Gitblit API client library
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildApiLibrary" depends="compile" description="Builds the Gitblit RPC client library">
|
| | | <echo>Building Gitblit API Library ${project.version}</echo>
|
| | | |
| | | <local name="javadoc.dir" />
|
| | | <property name="javadoc.dir" value="${project.outputDirectory}/javadoc" />
|
| | | <delete dir="${javadoc.dir}" />
|
| | |
|
| | | <!-- Build API Library jar -->
|
| | | <mx:genjar tag="" includeResources="false" excludeClasspathJars="true"
|
| | | destfile="${project.targetDirectory}/gbapi-${project.version}.jar">
|
| | | <class name="com.gitblit.Keys" />
|
| | | <class name="com.gitblit.client.GitblitClient" />
|
| | | <class name="com.gitblit.models.FederationModel" />
|
| | | <class name="com.gitblit.models.FederationProposal" />
|
| | | <class name="com.gitblit.models.FederationSet" /> |
| | | </mx:genjar>
|
| | |
|
| | | <!-- Build API Library jar -->
|
| | | <genjar jarfile="gbapi-${gb.version}.jar">
|
| | | <class name="com.gitblit.Keys" />
|
| | | <class name="com.gitblit.client.GitblitClient" />
|
| | | <classpath refid="master-classpath" />
|
| | | <classfilter>
|
| | | <exclude name="com.google.gson." />
|
| | | <exclude name="com.sun.syndication." />
|
| | | </classfilter>
|
| | | <manifest>
|
| | | <attribute name="Specification-Version" value="${gb.version}" />
|
| | | <attribute name="Release-Date" value="${gb.versionDate}" />
|
| | | </manifest>
|
| | | </genjar>
|
| | | |
| | | <!-- Build API sources jar -->
|
| | | <zip destfile="gbapi-${gb.version}-sources.jar">
|
| | | <fileset dir="${basedir}/src" defaultexcludes="yes">
|
| | | <include name="com/gitblit/Constants.java"/>
|
| | | <include name="com/gitblit/GitBlitException.java"/>
|
| | | <include name="com/gitblit/Keys.java"/>
|
| | | <include name="com/gitblit/client/**/*.java"/>
|
| | | <include name="com/gitblit/models/**/*.java"/>
|
| | | <include name="com/gitblit/utils/**/*.java"/> |
| | | </fileset>
|
| | | </zip>
|
| | | |
| | | <!-- Build API JavaDoc jar -->
|
| | | <javadoc destdir="${basedir}/javadoc">
|
| | | <fileset dir="${basedir}/src" defaultexcludes="yes">
|
| | | <include name="com/gitblit/Constants.java"/>
|
| | | <include name="com/gitblit/GitBlitException.java"/>
|
| | | <include name="com/gitblit/Keys.java"/>
|
| | | <include name="com/gitblit/client/**/*.java"/>
|
| | | <include name="com/gitblit/models/**/*.java"/>
|
| | | <include name="com/gitblit/utils/**/*.java"/> |
| | | </fileset>
|
| | | </javadoc>
|
| | | <zip destfile="gbapi-${gb.version}-javadoc.jar">
|
| | | <fileset dir="${basedir}/javadoc" />
|
| | | </zip>
|
| | | |
| | | <!-- Build the API library zip file -->
|
| | | <zip destfile="${gbapi.zipfile}">
|
| | | <fileset dir="${basedir}">
|
| | | <include name="gbapi-${gb.version}.jar" />
|
| | | <include name="gbapi-${gb.version}-sources.jar" />
|
| | | <include name="gbapi-${gb.version}-javadoc.jar" />
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | <fileset dir="${basedir}/ext">
|
| | | <include name="gson*.jar" />
|
| | | <exclude name="gson*-sources.jar" />
|
| | | <exclude name="gson*-javadoc.jar" />
|
| | | <include name="rome*.jar" />
|
| | | <exclude name="rome*-sources.jar" />
|
| | | <exclude name="rome*-javadoc.jar" />
|
| | | </fileset>
|
| | | </zip>
|
| | | </target>
|
| | | <!-- Build API sources jar -->
|
| | | <zip destfile="${project.targetDirectory}/gbapi-${project.version}-sources.jar">
|
| | | <fileset dir="${project.src.dir}" defaultexcludes="yes">
|
| | | <include name="com/gitblit/Constants.java"/>
|
| | | <include name="com/gitblit/GitBlitException.java"/>
|
| | | <include name="com/gitblit/Keys.java"/>
|
| | | <include name="com/gitblit/client/**/*.java"/>
|
| | | <include name="com/gitblit/models/**/*.java"/>
|
| | | <include name="com/gitblit/utils/**/*.java"/> |
| | | </fileset>
|
| | | </zip>
|
| | | |
| | | <!-- Build API JavaDoc jar -->
|
| | | <mx:javadoc destdir="${javadoc.dir}" redirect="true">
|
| | | <fileset dir="${project.src.dir}" defaultexcludes="yes">
|
| | | <include name="com/gitblit/Constants.java"/>
|
| | | <include name="com/gitblit/GitBlitException.java"/>
|
| | | <include name="com/gitblit/Keys.java"/>
|
| | | <include name="com/gitblit/client/**/*.java"/>
|
| | | <include name="com/gitblit/models/**/*.java"/>
|
| | | <include name="com/gitblit/utils/**/*.java"/> |
| | | </fileset>
|
| | | </mx:javadoc>
|
| | | |
| | | <zip destfile="${project.targetDirectory}/gbapi-${project.version}-javadoc.jar">
|
| | | <fileset dir="${javadoc.dir}" />
|
| | | </zip>
|
| | | |
| | | <!-- Build the API library zip file -->
|
| | | <mx:zip destfile="${project.targetDirectory}/${gbapi.zipfile}">
|
| | | <fileset dir="${basedir}">
|
| | | <include name="LICENSE" />
|
| | | <include name="NOTICE" />
|
| | | </fileset>
|
| | | <fileset dir="${project.targetDirectory}">
|
| | | <include name="gbapi-${project.version}.jar" />
|
| | | <include name="gbapi-${project.version}-sources.jar" />
|
| | | <include name="gbapi-${project.version}-javadoc.jar" />
|
| | | </fileset>
|
| | | <!-- include "api" tagged dependencies -->
|
| | | <dependencies prefix="ext" tag="api" />
|
| | | </mx:zip>
|
| | | |
| | | <!-- Cleanup -->
|
| | | <delete>
|
| | | <fileset dir="${project.targetDirectory}">
|
| | | <include name="javadoc/**" />
|
| | | <include name="gbapi-${project.version}.jar" />
|
| | | <include name="gbapi-${project.version}-sources.jar" />
|
| | | <include name="gbapi-${project.version}-javadoc.jar" />
|
| | | </fileset>
|
| | | </delete>
|
| | | </target>
|
| | |
|
| | |
|
| | | <!--
|
| | |
| | | Build the Gitblit Website
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildSite" depends="compile" description="Build the Gitblit website">
|
| | | <target name="buildSite" depends="prepare" description="Build the Gitblit website">
|
| | |
|
| | | <echo>Building Gitblit Website ${gb.version}</echo>
|
| | | <echo>Building Gitblit Website ${project.version}</echo>
|
| | |
|
| | | <property name="releaselog" value="${basedir}/releases.moxie" />
|
| | |
|
| | | <!-- Build Site -->
|
| | | <delete dir="${project.site.dir}" />
|
| | | <mkdir dir="${project.site.dir}" />
|
| | | <copy todir="${project.site.dir}">
|
| | | <!-- Copy selected Gitblit resources -->
|
| | | <fileset dir="${project.resources.dir}">
|
| | | <include name="bootstrap.140.css" />
|
| | | <include name="bootstrap.gb.css" />
|
| | | <include name="markdown.css" />
|
| | | <include name="gitblt_25_white.png" />
|
| | | <include name="gitblt-favicon.png" />
|
| | | <include name="lock_go_16x16.png" />
|
| | | <include name="lock_pull_16x16.png" />
|
| | | <include name="shield_16x16.png" />
|
| | | <include name="cold_16x16.png" />
|
| | | <include name="bug_16x16.png" />
|
| | | <include name="book_16x16.png" />
|
| | | <include name="blank.png" />
|
| | | <include name="federated_16x16.png" />
|
| | | <include name="arrow_page.png" />
|
| | | </fileset>
|
| | |
|
| | | <!-- Copy Doc images -->
|
| | | <fileset dir="${basedir}/docs">
|
| | | <include name="*.png" />
|
| | | <include name="*.js" />
|
| | | </fileset>
|
| | | </copy>
|
| | | <mx:doc googleplusid="114464678392593421684" googleanalyticsid="UA-24377072-1"
|
| | | googlePlusOne="true" minify="true" customless="custom.less">
|
| | | <structure>
|
| | | <menu name="about">
|
| | | <page name="overview" src="siteindex.mkd" out="index.html" headerLinks="false" />
|
| | | <page name="features" src="features.mkd" />
|
| | | <page name="screenshots" src="screenshots.mkd" />
|
| | | </menu>
|
| | | <menu name="documentation">
|
| | | <page name="setup" src="setup.mkd" />
|
| | | <page name="federation" src="federation.mkd" />
|
| | | <divider />
|
| | | <page name="settings" src="properties.mkd" />
|
| | | <page name="faq" src="faq.mkd" />
|
| | | <divider />
|
| | | <page name="design" src="design.mkd" />
|
| | | <page name="rpc" src="rpc.mkd" />
|
| | | </menu>
|
| | | |
| | | <menu name="releases">
|
| | | <page name="release notes" out="releasenotes.html">
|
| | | <template src="releasecurrent.ftl" data="${releaselog}" />
|
| | | </page>
|
| | | <page name="release history" out="releases.html">
|
| | | <template src="releasehistory.ftl" data="${releaselog}" />
|
| | | </page>
|
| | | <divider />
|
| | | <page name="roadmap" src="roadmap.mkd" /> |
| | | </menu>
|
| | | |
| | | <menu name="downloads">
|
| | | <link name="Gitblit GO (Windows)" src="${gc.url}gitblit-${project.releaseVersion}.zip" />
|
| | | <link name="Gitblit GO (Linux/OSX)" src="${gc.url}gitblit-${project.releaseVersion}.tar.gz" />
|
| | | <link name="Gitblit WAR" src="${gc.url}gitblit-${project.releaseVersion}.war" />
|
| | | <link name="Gitblit Express" src="${gc.url}express-${project.releaseVersion}.zip" />
|
| | | <divider />
|
| | | <link name="Gitblit Manager" src="${gc.url}manager-${project.releaseVersion}.zip" />
|
| | | <link name="Federation Client" src="${gc.url}fedclient-${project.releaseVersion}.zip" />
|
| | | <divider />
|
| | | <link name="API Library" src="${gc.url}gbapi-${project.releaseVersion}.zip" />
|
| | | </menu>
|
| | | |
| | | <menu name="links">
|
| | | <link name="Demo" src="https://demo-gitblit.rhcloud.com" />
|
| | | <divider />
|
| | | <link name="Github" src="${project.scmUrl}" />
|
| | | <link name="Issues" src="${project.issuesUrl}" />
|
| | | <link name="Discussion" src="${project.forumUrl}" />
|
| | | <link name="Google+" src="${project.socialNetworkUrl}" />
|
| | | <link name="Ohloh" src="http://www.ohloh.net/p/gitblit" />
|
| | | </menu>
|
| | | <divider />
|
| | | </structure>
|
| | | |
| | | <replace token="%GCURL%" value="${gc.url}" />
|
| | | |
| | | <properties token="%PROPERTIES%" file="${project.distrib.dir}/data/gitblit.properties" />
|
| | | |
| | | <regex searchPattern="\b(issue)(\s*[#]?|-){0,1}(\d+)\b" replacePattern="<a href='http://code.google.com/p/gitblit/issues/detail?id=$3'>issue $3</a>" />
|
| | | |
| | | <!-- Set the logo from the mx:doc resources -->
|
| | | <logo file="${project.resources.dir}/gitblt_25_white.png" />
|
| | | <favicon file="${project.resources.dir}/gitblt-favicon.png" />
|
| | | |
| | | <resource>
|
| | | <fileset dir="${project.resources.dir}">
|
| | | <include name="lock_go_16x16.png" />
|
| | | <include name="lock_pull_16x16.png" />
|
| | | <include name="shield_16x16.png" />
|
| | | <include name="cold_16x16.png" />
|
| | | <include name="bug_16x16.png" />
|
| | | <include name="book_16x16.png" />
|
| | | <include name="blank.png" />
|
| | | <include name="federated_16x16.png" />
|
| | | <include name="arrow_page.png" />
|
| | | </fileset>
|
| | | </resource>
|
| | | </mx:doc> |
| | |
|
| | | <!-- Copy Fancybox -->
|
| | | <mkdir dir="${project.site.dir}/fancybox" />
|
| | | <copy todir="${project.site.dir}/fancybox">
|
| | | <fileset dir="${basedir}/docs/fancybox">
|
| | | <exclude name="thumbs.db" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Copy google-code-prettify -->
|
| | | <mkdir dir="${basedir}/src/com/gitblit/wicket/pages/prettify" />
|
| | | <copy todir="${project.site.dir}/prettify">
|
| | | <fileset dir="${basedir}/src/com/gitblit/wicket/pages/prettify">
|
| | | <mkdir dir="${project.siteTargetDirectory}/fancybox" />
|
| | | <copy todir="${project.siteTargetDirectory}/fancybox">
|
| | | <fileset dir="${project.siteSourceDirectory}/fancybox">
|
| | | <exclude name="thumbs.db" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Generate thumbnails of screenshots -->
|
| | | <java classpath="${project.build.dir}" classname="com.gitblit.build.BuildThumbnails">
|
| | | <classpath refid="master-classpath" />
|
| | | |
| | | <arg value="--sourceFolder" />
|
| | | <arg value="${basedir}/docs/screenshots" />
|
| | | |
| | | <arg value="--destinationFolder" />
|
| | | <arg value="${project.site.dir}/thumbs" />
|
| | | |
| | | <arg value="--maximumDimension" />
|
| | | <arg value="250" />
|
| | | </java>
|
| | | <mx:thumbs input="png" output="png" maximumDimension="250" |
| | | sourceDir="${project.siteSourceDirectory}/screenshots"
|
| | | destDir="${project.siteTargetDirectory}/thumbs" />
|
| | |
|
| | | <!-- Copy screenshots -->
|
| | | <mkdir dir="${project.site.dir}/screenshots" />
|
| | | <copy todir="${project.site.dir}/screenshots">
|
| | | <fileset dir="${basedir}/docs/screenshots">
|
| | | <mkdir dir="${project.siteTargetDirectory}/screenshots" />
|
| | | <copy todir="${project.siteTargetDirectory}/screenshots">
|
| | | <fileset dir="${project.siteSourceDirectory}/screenshots">
|
| | | <include name="*.png" />
|
| | | </fileset>
|
| | | </copy>
|
| | |
|
| | | <!-- Build site pages -->
|
| | | <java classpath="${project.build.dir}" classname="com.gitblit.build.BuildSite">
|
| | | <classpath refid="master-classpath" />
|
| | | <arg value="--sourceFolder" />
|
| | | <arg value="${basedir}/docs" />
|
| | |
|
| | | <arg value="--outputFolder" />
|
| | | <arg value="${project.site.dir}" />
|
| | |
|
| | | <arg value="--pageHeader" />
|
| | | <arg value="${basedir}/docs/site_header.html" />
|
| | | |
| | | <arg value="--pageFooter" />
|
| | | <arg value="${basedir}/docs/site_footer.html" />
|
| | |
|
| | | <arg value="--analyticsSnippet" />
|
| | | <arg value="${basedir}/docs/site_analytics.html" />
|
| | | |
| | | <arg value="--adSnippet" />
|
| | | <arg value="${basedir}/docs/site_ads.html" />
|
| | |
|
| | | <arg value="--alias" />
|
| | | <arg value="index=overview" />
|
| | |
|
| | | <arg value="--alias" />
|
| | | <arg value="properties=settings" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%VERSION%=${gb.version}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%GO%=${distribution.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%WAR%=${distribution.warfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%FEDCLIENT%=${fedclient.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%MANAGER%=${manager.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%API%=${gbapi.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%EXPRESS%=${express.zipfile}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%BUILDDATE%=${gb.versionDate}" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%JGIT%=${jgit.version}" />
|
| | |
|
| | | <arg value="--properties" />
|
| | | <arg value="%PROPERTIES%=${basedir}/distrib/gitblit.properties" />
|
| | | |
| | | <arg value="--nomarkdown" />
|
| | | <arg value="%BEGINCODE%:%ENDCODE%" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value=""%BEGINCODE%=<pre class='prettyprint lang-java'>"" />
|
| | |
|
| | | <arg value="--substitute" />
|
| | | <arg value="%ENDCODE%=</pre>" />
|
| | |
|
| | | <arg value="--regex" />
|
| | | <arg value=""\b(issue)(\s*[#]?|-){0,1}(\d+)\b!!!<a href='http://code.google.com/p/gitblit/issues/detail?id=$3'>issue $3</a>"" />
|
| | |
|
| | | </java> |
| | | </target>
|
| | |
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Compile from source, publish binaries, and build & deploy site
|
| | | Build all binaries and site
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="buildAll" depends="buildGO,buildWAR,buildOpenShift,buildFederationClient,buildManager,buildApiLibrary,buildSite"> |
| | | <!-- Cleanup -->
|
| | | <delete dir="${project.build.dir}" />
|
| | | <delete dir="${project.war.dir}" />
|
| | | <delete dir="${project.deploy.dir}" />
|
| | | <delete dir="${project.express.dir}" />
|
| | | </target>
|
| | | <target name="buildAll" depends="buildAuthority,buildGO,buildWAR,buildExpress,buildFederationClient,buildManager,buildApiLibrary,buildSite" /> |
| | |
|
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| | | Update the gh-pages branch with the current site
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="updateGhPages" depends="buildSite">
|
| | | <!-- Build gh-pages branch -->
|
| | | <mx:ghpages repositorydir="${basedir}" obliterate="true" />
|
| | | </target>
|
| | | |
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Publish binaries to Google Code
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="publishBinaries" depends="buildGO,buildWAR,buildOpenShift,buildFederationClient,buildManager" description="Publish the Gitblit binaries to Google Code">
|
| | | <target name="publishBinaries" depends="clean,buildGO,buildWAR,buildExpress,buildFederationClient,buildManager,buildApiLibrary" description="Publish the Gitblit binaries to Google Code">
|
| | |
|
| | | <echo>Uploading Gitblit ${gb.version} binaries</echo>
|
| | | <echo>Uploading Gitblit ${project.version} binaries</echo>
|
| | |
|
| | | <!-- Upload Gitblit GO ZIP file -->
|
| | | <gcupload |
| | | username="${googlecode.user}" |
| | | password="${googlecode.password}" |
| | | projectname="gitblit" |
| | | filename="${distribution.zipfile}" |
| | | targetfilename="gitblit-${gb.version}.zip"
|
| | | summary="Gitblit GO v${gb.version} (standalone, integrated Gitblit server)"
|
| | | labels="Featured, Type-Package, OpSys-All" />
|
| | | <!-- Upload Gitblit GO Windows ZIP file -->
|
| | | <mx:gcupload |
| | | sourceFile="${distribution.zipfile}" |
| | | targetFile="gitblit-${project.version}.zip"
|
| | | description="Gitblit GO v${project.version} (standalone, integrated Gitblit server for Windows)" />
|
| | |
|
| | | <!-- Upload Gitblit GO Linux/Unix tar.gz file -->
|
| | | <mx:gcupload
|
| | | sourceFile="${distribution.tgzfile}" |
| | | targetFile="gitblit-${project.version}.tar.gz"
|
| | | description="Gitblit GO v${project.version} (standalone, integrated Gitblit server for Linux/Unix)" />
|
| | |
|
| | | <!-- Upload Gitblit WAR file -->
|
| | | <gcupload |
| | | username="${googlecode.user}" |
| | | password="${googlecode.password}" |
| | | projectname="gitblit" |
| | | filename="${distribution.warfile}" |
| | | targetfilename="gitblit-${gb.version}.war"
|
| | | summary="Gitblit WAR v${gb.version} (standard WAR webapp for servlet containers)"
|
| | | labels="Featured, Type-Package, OpSys-All" />
|
| | | <mx:gcupload |
| | | sourceFile="${distribution.warfile}" |
| | | targetFile="gitblit-${project.version}.war"
|
| | | description="Gitblit WAR v${project.version} (standard WAR webapp for servlet containers)" />
|
| | |
|
| | | <!-- Upload Gitblit FedClient -->
|
| | | <gcupload |
| | | username="${googlecode.user}" |
| | | password="${googlecode.password}" |
| | | projectname="gitblit" |
| | | filename="${fedclient.zipfile}" |
| | | targetfilename="fedclient-${gb.version}.zip"
|
| | | summary="Gitblit Federation Client v${gb.version} (command-line tool to clone data from federated Gitblit instances)"
|
| | | labels="Featured, Type-Package, OpSys-All" />
|
| | | <mx:gcupload |
| | | sourceFile="${fedclient.zipfile}" |
| | | targetFile="fedclient-${project.version}.zip"
|
| | | description="Gitblit Federation Client v${project.version} (command-line tool to clone data from federated Gitblit instances)" />
|
| | |
|
| | | <!-- Upload Gitblit Manager -->
|
| | | <gcupload |
| | | username="${googlecode.user}" |
| | | password="${googlecode.password}" |
| | | projectname="gitblit" |
| | | filename="${manager.zipfile}" |
| | | targetfilename="manager-${gb.version}.zip"
|
| | | summary="Gitblit Manager v${gb.version} (Swing tool to remotely administer a Gitblit server)"
|
| | | labels="Featured, Type-Package, OpSys-All" />
|
| | | <mx:gcupload
|
| | | sourceFile="${manager.zipfile}" |
| | | targetFile="manager-${project.version}.zip"
|
| | | description="Gitblit Manager v${project.version} (Swing tool to remotely administer a Gitblit server)" />
|
| | |
|
| | | <!-- Upload Gitblit API Library -->
|
| | | <gcupload |
| | | username="${googlecode.user}" |
| | | password="${googlecode.password}" |
| | | projectname="gitblit" |
| | | filename="${gbapi.zipfile}" |
| | | targetfilename="gbapi-${gb.version}.zip"
|
| | | summary="Gitblit API Library v${gb.version} (JSON RPC library to integrate with your software)"
|
| | | labels="Featured, Type-Package, OpSys-All" />
|
| | | <mx:gcupload
|
| | | sourceFile="${gbapi.zipfile}" |
| | | targetFile="gbapi-${project.version}.zip"
|
| | | description="Gitblit API Library v${project.version} (JSON RPC library to integrate with your software)" />
|
| | |
|
| | | <!-- Upload Gitblit Express for RedHat OpenShift -->
|
| | | <gcupload |
| | | username="${googlecode.user}" |
| | | password="${googlecode.password}" |
| | | projectname="gitblit" |
| | | filename="${express.zipfile}" |
| | | targetfilename="express-${gb.version}.zip"
|
| | | summary="Gitblit Express v${gb.version} (run Gitblit on RedHat's OpenShift cloud)"
|
| | | labels="Featured, Type-Package, OpSys-All" />
|
| | | <mx:gcupload |
| | | sourceFile="${express.zipfile}" |
| | | targetFile="express-${project.version}.zip"
|
| | | description="Gitblit Express v${project.version} (run Gitblit on RedHat's OpenShift cloud)" />
|
| | |
|
| | | </target>
|
| | |
|
| | |
| | | You must add ext/commons-net-1.4.0.jar to your ANT classpath.
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="publishSite" depends="buildSite" description="Publish the Gitblit site to a webserver (requires ext/commons-net-1.4.0.jar)" >
|
| | | <target name="publishSite" depends="clean,buildSite,updateGhPages" description="Publish the Gitblit site to a webserver (requires ext/commons-net-1.4.0.jar)" >
|
| | |
|
| | | <echo>Uploading Gitblit ${gb.version} website</echo>
|
| | | <echo>Uploading Gitblit ${project.version} website</echo>
|
| | |
|
| | | <ftp server="${ftp.server}"
|
| | | userid="${ftp.user}"
|
| | |
| | | remotedir="${ftp.dir}"
|
| | | passive="true"
|
| | | verbose="yes">
|
| | | <fileset dir="${project.site.dir}" />
|
| | | <fileset dir="${project.siteTargetDirectory}" />
|
| | | </ftp>
|
| | | </target>
|
| | |
|
| | |
| | | Compile from source, publish binaries, and build & deploy site
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="publishAll" depends="publishBinaries,publishSite">
|
| | | <!-- Cleanup -->
|
| | | <delete dir="${project.build.dir}" />
|
| | | <delete dir="${project.war.dir}" />
|
| | | <delete dir="${project.deploy.dir}" />
|
| | | <target name="publishAll" depends="publishBinaries,publishSite" />
|
| | |
|
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| | | Tag a new version and prepare for the next development cycle.
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| | | -->
|
| | | <target name="tagRelease" depends="prepare">
|
| | | <!-- release -->
|
| | | <property name="dryrun" value="false" />
|
| | | <mx:version stage="release" dryrun="${dryrun}" /> |
| | | <!-- commit build.moxie & releases.moxie (automatic) -->
|
| | | <mx:commit showtitle="no">
|
| | | <message>Prepare ${project.version} release</message>
|
| | | <tag name="v${project.version}">
|
| | | <message>${project.name} ${project.version} release</message>
|
| | | </tag>
|
| | | </mx:commit>
|
| | |
|
| | | <!-- next cycle -->
|
| | | <mx:version stage="snapshot" incrementNumber="incremental" dryrun="${dryrun}" />
|
| | | <mx:commit showtitle="no">
|
| | | <message>Reset build identifiers for next development cycle</message>
|
| | | </mx:commit>
|
| | | </target>
|
| | | </project> |
| | |
|
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Build Gitblit Docs
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <macrodef name="generateDocs">
|
| | | <attribute name="toDir"/>
|
| | | <sequential>
|
| | | <mx:doc toDir="@{toDir}" minify="true" customless="custom.less">
|
| | | <structure>
|
| | | <menu name="about">
|
| | | <page name="overview" src="siteindex.mkd" out="index.html" headerLinks="false" />
|
| | | <page name="features" src="features.mkd" />
|
| | | </menu>
|
| | | <menu name="documentation">
|
| | | <page name="setup" src="setup.mkd" />
|
| | | <page name="federation" src="federation.mkd" />
|
| | | <divider />
|
| | | <page name="faq" src="faq.mkd" />
|
| | | <page name="settings" src="properties.mkd" />
|
| | | <divider />
|
| | | <page name="design" src="design.mkd" />
|
| | | <page name="rpc" src="rpc.mkd" />
|
| | | </menu>
|
| | | <menu name="changelog">
|
| | | <page name="current release" src="releasecurrent.mkd" />
|
| | | <page name="older releases" src="releasehistory.mkd" />
|
| | | </menu>
|
| | | <menu name="links">
|
| | | <link name="Demo" src="https://demo-gitblit.rhcloud.com" />
|
| | | <divider />
|
| | | <link name="Github" src="${project.scmUrl}" />
|
| | | <link name="Issues" src="${project.issuesUrl}" />
|
| | | <link name="Discussion" src="${project.forumUrl}" />
|
| | | <link name="Google+" src="${project.socialNetworkUrl}" />
|
| | | <link name="Ohloh" src="http://www.ohloh.net/p/gitblit" />
|
| | | </menu>
|
| | | </structure>
|
| | | |
| | | <properties token="%PROPERTIES%" file="${project.distrib.dir}/data/gitblit.properties" />
|
| | | |
| | | <regex searchPattern="\b(issue)(\s*[#]?|-){0,1}(\d+)\b" replacePattern="<a href='http://code.google.com/p/gitblit/issues/detail?id=$3'>issue $3</a>" />
|
| | | |
| | | <!-- Set the logo from the mx:doc resources -->
|
| | | <logo file="${project.resources.dir}/gitblt_25_white.png" />
|
| | | <favicon file="${project.resources.dir}/gitblt-favicon.png" />
|
| | | |
| | | <resource>
|
| | | <fileset dir="${project.resources.dir}">
|
| | | <include name="lock_go_16x16.png" />
|
| | | <include name="lock_pull_16x16.png" />
|
| | | <include name="shield_16x16.png" />
|
| | | <include name="cold_16x16.png" />
|
| | | <include name="bug_16x16.png" />
|
| | | <include name="book_16x16.png" />
|
| | | <include name="blank.png" />
|
| | | <include name="federated_16x16.png" />
|
| | | <include name="arrow_page.png" />
|
| | | </fileset>
|
| | | </resource>
|
| | | </mx:doc>
|
| | | </sequential>
|
| | | </macrodef>
|
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| | | Macro to create a pristine data directory for the target build
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <macrodef name="prepareDataDirectory">
|
| | | <attribute name="toDir"/>
|
| | | <sequential>
|
| | | <mkdir dir="@{toDir}" />
|
| | | <copy todir="@{toDir}" overwrite="false">
|
| | | <fileset dir="${project.distrib.dir}/data">
|
| | | <include name="users.conf" />
|
| | | <include name="projects.conf" />
|
| | | <include name="gitblit.properties" />
|
| | | </fileset>
|
| | | </copy>
|
| | | <mkdir dir="@{toDir}/groovy" />
|
| | | <copy todir="@{toDir}/groovy">
|
| | | <fileset dir="${project.distrib.dir}/data/groovy"> |
| | | <include name="sendmail.groovy" />
|
| | | <include name="sendmail-html.groovy" />
|
| | | <include name="jenkins.groovy" />
|
| | | <include name="protect-refs.groovy" />
|
| | | <include name="fogbugz.groovy" />
|
| | | <include name="thebuggenie.groovy" />
|
| | | </fileset>
|
| | | </copy>
|
| | | </sequential>
|
| | | </macrodef>
|
| | | |
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| | | Macro to upload binaries to GoogleCode
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <macrodef name="googleUpload">
|
| | | <attribute name="sourceFile"/>
|
| | | <attribute name="targetFile"/>
|
| | | <attribute name="description"/>
|
| | | <sequential>
|
| | | <gcupload |
| | | username="${googlecode.user}" |
| | | password="${googlecode.password}" |
| | | projectname="gitblit" |
| | | filename="${project.targetDirectory}/@{sourceFile}" |
| | | targetfilename="@{targetFile}"
|
| | | summary="@{description}"
|
| | | labels="Featured, Type-Package, OpSys-All" /> |
| | | </sequential>
|
| | | </macrodef>
|
| | |
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Install Gitblit JAR for usage as Maven module
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="installMaven" depends="compile" description="Install Gitblit JAR as Maven module">
|
| | | <local name="project.jar" />
|
| | | <property name="project.jar" value="${project.outputDirectory}/gitblit.jar" />
|
| | | <mx:jar destfile="${project.jar}" includeresources="true" />
|
| | |
|
| | | <exec executable="mvn">
|
| | | <arg value="install:install-file" />
|
| | | <arg value="-Dfile=${project.jar}" />
|
| | | <arg value="-DpomFile=${basedir}/pom.xml" />
|
| | | <arg value="-DcreateChecksum=true" />
|
| | | </exec>
|
| | | </target>
|
| | |
|
| | | <!--
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | Upload Gitblit JAR to remote Maven repository
|
| | | |
| | | build.properties:
|
| | | project.maven.repo.url = http://whatever.com/maven2
|
| | | project.maven.repo.id = whateverId
|
| | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| | | -->
|
| | | <target name="uploadMaven" depends="compile" description="Upload Gitblit JAR to remote Maven repository">
|
| | | <local name="project.jar" />
|
| | | <property name="project.jar" value="${project.outputDirectory}/gitblit.jar" />
|
| | | <mx:jar destfile="${project.jar}" includeresources="true" />
|
| | |
|
| | | <exec executable="mvn">
|
| | | <arg value="deploy:deploy-file" />
|
| | | <arg value="-Dfile=${project.jar}" />
|
| | | <arg value="-DpomFile=${basedir}/pom.xml" />
|
| | | <arg value="-Durl=${project.maven.repo.url}" />
|
| | | <arg value="-DrepositoryId=${project.maven.repo.id}" />
|
| | | <arg value="-DcreateChecksum=true" />
|
| | | </exec>
|
| | | </target> |
| | | </project>
|