]> git.proxmox.com Git - extjs.git/blame - extjs/examples/modern/stockapp/.sencha/app/find-cmd-impl.xml
add extjs 6.0.1 sources
[extjs.git] / extjs / examples / modern / stockapp / .sencha / app / find-cmd-impl.xml
CommitLineData
6527f429
DM
1<project name="find-cmd-impl">\r
2 <!--\r
3 Run "sencha which" to find the Sencha Cmd basedir and get "cmd.dir" setup. We\r
4 need to execute the command with curdir set properly for Cmd to pick up that we\r
5 are running for an application.\r
6 -->\r
7 <target name="find-cmd-in-path" unless="cmd.dir">\r
8 <exec executable="sencha" \r
9 dir="${basedir}" \r
10 failifexecutionfails="false" \r
11 outputproperty="exec.error">\r
12 <arg value="which"/>\r
13 <arg value="-p=cmd.dir"/>\r
14 <arg value="-o=$cmddir$"/>\r
15 </exec>\r
16\r
17 <!-- Now read the generated properties file and delete it -->\r
18 <property file="$cmddir$"/>\r
19 <delete file="$cmddir$"/>\r
20 </target>\r
21\r
22 <!--\r
23 Run "sencha which" again, similar to the above target, but explicitly check\r
24 for the 'SENCHA_CMD' environment variable to have been set, in case sencha \r
25 cmd isn't on the current path settings for the user\r
26 -->\r
27 <target name="find-cmd-in-environment" unless="cmd.dir">\r
28 <exec executable="${env.SENCHA_CMD}/sencha" \r
29 dir="${basedir}"\r
30 failifexecutionfails="false">\r
31 <arg value="which"/>\r
32 <arg value="-p=cmd.dir"/>\r
33 <arg value="-o=$cmddir$"/>\r
34 </exec>\r
35\r
36 <property file="$cmddir$"/>\r
37 <delete file="$cmddir$"/>\r
38 </target>\r
39\r
40 <!--\r
41 == Mac OSX launchd fix ==\r
42 create a child shell process that will source in ~/.bash_profile\r
43 and then attempt to call 'sencha which' with the current user's \r
44 shell profile settings. sencha which will create a properties file\r
45 that can then be loaded into this (the parent) process.\r
46 \r
47 This allows ant integrations in IDE's like netbeans or eclipse to properly\r
48 locate Sencha Cmd, even if the IDE was launched via launchd (Finder)\r
49 -->\r
50 <target name="find-cmd-in-shell" unless="cmd.dir">\r
51 <delete quiet="true" file="$cmddir$"/>\r
52 <echo file="tmp.sh"> source ~/.bash_profile; sencha which -p cmd.dir -o '$cmddir$'</echo>\r
53 <exec executable="/bin/sh"><arg value="tmp.sh"/></exec>\r
54 <property file="$cmddir$"/>\r
55 <delete file="tmp.sh"/>\r
56 <delete file="$cmddir$"/>\r
57 </target>\r
58</project>