From dcd6541d4e7a159e7478962121fbfd0782568af0 Mon Sep 17 00:00:00 2001 From: James Moger <james.moger@gitblit.com> Date: Mon, 09 Jun 2014 12:36:09 -0400 Subject: [PATCH] Switch to basic ant copy filter for web.xml --- build.xml | 22 ++++++++++++++++++---- 1 files changed, 18 insertions(+), 4 deletions(-) diff --git a/build.xml b/build.xml index be6f1dd..035f189 100644 --- a/build.xml +++ b/build.xml @@ -174,7 +174,18 @@ <property name="go.dir" value="${project.outputDirectory}/go" /> <delete dir="${go.dir}" /> + <local name="webinf" /> + <property name="webinf" value="${project.compileOutputDirectory}/WEB-INF" /> + <prepareDataDirectory toDir="${go.dir}/data" /> + + <!-- Copy the web.xml from the prototype web.xml --> + <copy todir="${webinf}" overwrite="true"> + <fileset file="${project.src.dir}/WEB-INF/web.xml" /> + <filterset> + <filter token="gb.version" value="${project.version}" /> + </filterset> + </copy> <!-- Build jar --> <mx:jar destfile="${go.dir}/gitblit.jar" includeresources="true"> @@ -240,10 +251,13 @@ <!-- 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"> - <replace token="@gb.version@" value="${project.version}" /> - </mx:webxml> + <!-- Copy the web.xml from the prototype web.xml --> + <copy todir="${webinf}" overwrite="true"> + <fileset file="${project.src.dir}/WEB-INF/web.xml" /> + <filterset> + <filter token="gb.version" value="${project.version}" /> + </filterset> + </copy> <!-- Gitblit jar --> <mx:jar destfile="${webinf}/lib/gitblit.jar" includeresources="false" /> -- Gitblit v1.9.1