SVN Stats

From sselab

(Difference between revisions)
Jump to: navigation, search
(Services involved)
Line 1: Line 1:
 +
[[File:Screenshot-SVN_Stats.JPG|right|400px]]
Agile software development needs ever running integrated software. Tool support is essential. We provide the following services and are working on further ones, such as [[nightly build]] and [[automatic deployment of web systems]] that are developed. Coming soon.
Agile software development needs ever running integrated software. Tool support is essential. We provide the following services and are working on further ones, such as [[nightly build]] and [[automatic deployment of web systems]] that are developed. Coming soon.
== Services involved ==
== Services involved ==
-
[[File:Screenshot-SVN_Stats.JPG|right|400px]]
 
* [[Subversion]]
* [[Subversion]]
* [[Storage]]
* [[Storage]]

Revision as of 09:46, 12 February 2013

Agile software development needs ever running integrated software. Tool support is essential. We provide the following services and are working on further ones, such as nightly build and automatic deployment of web systems that are developed. Coming soon.

Services involved

A number of additional services are available. Check out what you want to use, e.g. to generate code or tests.

Initial setup

  • Use Subversion as your version control system for your software project
  • Integrate StatsSVN into your Continous Integration process
    • Download StatsSVN from Link
    • Add additional build-steps to e.g.: Ant
      • Set following properties:
   <property name="bin.dir" value="/usr/bin" />
   <property name="svn" value="${bin.dir}/svn" />
   <property name="webdav" value="${bin.dir}/cadaver" />

   <property name="repository-user" value="sselab-username" />
   <property name="repository-password" value="sselab-password" />

   <property name="repository-url" value="https://sselab.de/SVN-Repository-URL" />
   <property name="trac-url" value="https://sselab.de/TRAC-Project-URL" />

   <property name="repository-log" value="build/repository.log" />
   <property name="working-copy" value="RELATIVE_PATH_TO_WORKING_COPY" />
      • Create svn log file:
<target name="fetchSvnLog">
      <mkdir dir="build" />
      <exec executable="${svn}" output="${repository-log}">
           <arg line="log --username ${repository-user} --password ${repository-password} --non-interactive --no-auth-cache -v --xml ${repository-url}" />
       </exec>
   </target>
      • Calculate SVN stats
<target name="createStats" >

       <java jar="ext-lib/statsvn.jar" fork="true" failonerror="true">
           <arg value="-output-dir" />
           <arg value="build/stats" />

           <arg value="-cache-dir" />
           <arg value="build/cache" />

           <arg value="-config-file" />
           <arg value="config.properties" />

           <arg value="-username" />
           <arg value="${repository-user}" />
           <arg value="-password" />
           <arg value="${repository-password}" />

           <arg value="-trac" />
           <arg value="${trac-url}" />

           <arg value="-threads" />
           <arg value="2" />

           <arg value="${repository-log}" />
           <arg value="${working-copy}" />
       </java>

   </target>
  • Upload the generated html report of Stats_SVN to the project storage
    • Install a WebDAV-Client, e.g. cadaver Link
    • Add additional build-steps to e.g.: Ant
<target name="uploadStats">
       <exec executable="${webdav}" input="uploadWebDav.cadaver" dir="build/stats">
       </exec>
   </target>
open https://sselab.de/STORAGE_service-URL
mput *
    • In order to use the autologin feature from cadaver, you have to create the .netrc file:
machine sselab.de
login sselab-username
password sselab-password

Send feedback to extend this scenario

Please contact us if you have question concerning the usage of the services. We are also curious about new ideas for additional services and new usage scenarios. Send us a message over the contact form or write us an email