Commit 7acd6bfc authored by Tyrannas's avatar Tyrannas

installation automatique des packages

parent c9378a2e
<?xml version="1.0" encoding="UTF-8"?>
<project name="antModule" default="main" basedir="./">
<taskdef resource="net/sf/antcontrib/antlib.xml">
<classpath>
<pathelement location="lib/ant-contrib.jar"/>
</classpath>
</taskdef>
<taskdef resource="net/sf/antcontrib/antlib.xml">
<classpath>
<pathelement location="lib/ant-contrib.jar"/>
</classpath>
</taskdef>
<property name="node" value="false" ></property>
......@@ -38,7 +38,7 @@
</target>
<target name="unZip">
<unzip src="./input/${file}" dest="./input/unziped/" overwrite="false"/>
<unzip src="./input/${file}" dest="./input/unziped/" overwrite="false"/>
</target>
<target name="transformation">
......@@ -50,9 +50,10 @@
<mkdir dir="./input/unziped"/>
</sequential>
</target>
<target name="insertion" if="wantToInsert">
<antcall target="installModules"/>
<exec executable="node" dir="./node">
<arg line="insert.js"/>
</exec>
......@@ -64,4 +65,19 @@
</condition>
</target>
<target name="checkModules">
<condition property="modNotInstalled">
<not>
<available file="node_modules" type="dir"/>
</not>
</condition>
</target>
<target name="installModules" depends="checkModules" if="modNotInstalled">
<echo>"modules non installés"</echo>
<exec executable="npm" dir=".">
<arg line="install"/>
</exec>
</target>
</project>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment