[tor-commits] [metrics-web/master] Adds an Ant target to generate PNGs using Graphviz

karsten at torproject.org karsten at torproject.org
Sun Mar 4 19:46:02 UTC 2018


commit 252d4635df29db2a984f4bf75e0b0a8910e44370
Author: Iain R. Learmonth <irl at fsfe.org>
Date:   Sat Mar 3 06:35:34 2018 +0000

    Adds an Ant target to generate PNGs using Graphviz
---
 build.xml | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/build.xml b/build.xml
index 4b67ae6..59f3720 100644
--- a/build.xml
+++ b/build.xml
@@ -220,6 +220,21 @@
     </exec>
   </target>
 
+  <target name="generate-graphviz-pngs" >
+    <apply executable="dot"
+           dest="${basedir}/src/main/resources/web/images"
+           verbose="true" >
+      <arg value="-Tpng" />
+      <arg value="-o" />
+      <targetfile />
+      <srcfile />
+      <fileset dir="${basedir}/src/main/resources/graphviz" >
+        <include name="*.gv" />
+      </fileset>
+      <mapper type="glob" from="*.gv" to="*.png" />
+    </apply>
+  </target>
+
   <!-- This can be adapted to point at the actual work directory. -->
   <property name="prepare.deployment"
             value="/srv/metrics.torproject.org/metrics/work" />





More information about the tor-commits mailing list