1
<project default="invalid">
2
<target name="invalid">
3
<fail>Don't call this file directly.</fail>
6
<taskdef resource="net/sf/antcontrib/antcontrib.properties">
7
<classpath location="${antcontrib.jar}"/>
10
<!-- targets used to check if a shell exists -->
11
<target name="hassh"> <shellscript shell="sh"/> </target>
12
<target name="hasbash"> <shellscript shell="bash"/> </target>
13
<target name="hasperl"> <shellscript shell="perl"/> </target>
14
<target name="haspython"> <shellscript shell="python"/> </target>
15
<target name="hassed">
16
<!-- Temporary hack, since SED is hanging the tests on windows -->
18
<shellscript shell="sed"/>
20
<target name="hascmd">
21
<shellscript shell="cmd.exe" tmpsuffix=".bat">
27
<target name="sh.hello">
28
<shellscript shell="sh">
33
<target name="bash.hello">
34
<shellscript shell="bash">
39
<!-- python needs to start on the first col -->
40
<target name="python.hello">
41
<shellscript shell="python">
46
<target name="perl.hello">
47
<shellscript shell="perl">
48
print STDOUT "hello world\n";
52
<target name="noshell">
53
<shellscript shell="!!!!^^^a shell that should not exist^^^^^!!!!"/>
57
<target name="sh.inputstring">
58
<shellscript shell="sh" inputstring="echo hello world"/>
61
<target name="sed.test">
62
<shellscript shell="sed" >
64
<arg value="s/FOO/BAR/g"/>
65
FOO bar bar bar FOO bar bar
69
<target name="sh.property">
70
<property name="my.sh.property" value="this is a property"/>
71
<shellscript executable="sh">
72
echo ${my.sh.property}
76
<target name="sh.set.property">
77
<shellscript shell="sh" outputproperty="sh.set.property">
82
<target name="sh.tmp.suffix">
83
<shellscript shell="sh" tmpsuffix=".bat">
88
<target name="cmd.test">
89
<shellscript shell="cmd.exe" tmpsuffix=".bat">
96
<target name="dir.test">
98
<shellscript shell="sh" dir="subdir" outputproperty="dir.test.property">
100
echo "dir is $current"
102
<delete dir="subdir"/>
105
<target name="command.test">
106
<shellscript command="this should not work"/>