PageRenderTime 40ms CodeModel.GetById 37ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/bundles/plugins-trunk/Console/console/commands/qmake.xml

#
XML | 48 lines | 40 code | 5 blank | 3 comment | 0 complexity | 5173eea16098d828b027ff2eeb2b9e10 MD5 | raw file
 1<?xml version="1.0" ?>
 2
 3<!-- Attempt at invoking qmake from the current buffer's directory -->
 4<!--  Alan Ezust -->
 5
 6<!DOCTYPE COMMANDO SYSTEM "commando.dtd">
 7
 8<COMMANDO>
 9	<UI>
10        <CHOICE LABEL="qmake in" VARNAME="makeIn" DEFAULT="projectroot">
11            <OPTION LABEL="Project Root" VALUE="projectroot" />
12            <OPTION LABEL="Source Dir" VALUE="sourcedir" />
13            <OPTION LABEL="Custom Location" VALUE="customloc" />
14        </CHOICE>
15        <DIR_ENTRY LABEL="Source Dir" 
16         VARNAME = "sourcedir"
17         EVAL = 'new File(buffer.getPath()).getParent()' />    
18		<!-- <CAPTION LABEL="Config"> -->
19        <DIR_ENTRY LABEL="Project Root" 
20         VARNAME = "projectroot"
21         EVAL = 'getProjectRoot(view, buffer)' />
22         <DIR_ENTRY LABEL="Custom Location" VARNAME = "customlocation" />         
23    
24		<TOGGLE LABEL="Build Project file" VARNAME="makeProject" />
25		<ENTRY LABEL="Project file to use" VARNAME="projectFile" 
26                        DEFAULT=" " />
27	</UI>
28
29	<COMMANDS>
30        <COMMAND CONFIRM="FALSE" SHELL="System">
31        if (makeIn.equals("projectroot")) {
32            location = projectroot;
33        }
34        else if (makeIn.equals("customloc")) {
35            location = customlocation;
36        }
37        else location=sourcedir;
38		return "cd \"" + location + "\"";
39		</COMMAND>
40		<COMMAND SHELL="System" CONFIRM="FALSE">
41			buf = new StringBuffer();
42			buf.append("qmake ");
43			if (makeProject) buf.append("-project ");
44			buf.append(projectFile);
45			buf.toString();
46		</COMMAND>
47	</COMMANDS>
48</COMMANDO>