ace.define("ace/mode/batchfile_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(r,e,m){"use strict";var o=r("../lib/oop");var T=r("./text_highlight_rules").TextHighlightRules;var B=function(){this.$rules={start:[{token:'keyword.command.dosbatch',regex:'\\b(?:append|assoc|at|attrib|break|cacls|cd|chcp|chdir|chkdsk|chkntfs|cls|cmd|color|comp|compact|convert|copy|date|del|dir|diskcomp|diskcopy|doskey|echo|endlocal|erase|fc|find|findstr|format|ftype|graftabl|help|keyb|label|md|mkdir|mode|more|move|path|pause|popd|print|prompt|pushd|rd|recover|ren|rename|replace|restore|rmdir|set|setlocal|shift|sort|start|subst|time|title|tree|type|ver|verify|vol|xcopy)\\b',caseInsensitive:true},{token:'keyword.control.statement.dosbatch',regex:'\\b(?:goto|call|exit)\\b',caseInsensitive:true},{token:'keyword.control.conditional.if.dosbatch',regex:'\\bif\\s+not\\s+(?:exist|defined|errorlevel|cmdextversion)\\b',caseInsensitive:true},{token:'keyword.control.conditional.dosbatch',regex:'\\b(?:if|else)\\b',caseInsensitive:true},{token:'keyword.control.repeat.dosbatch',regex:'\\bfor\\b',caseInsensitive:true},{token:'keyword.operator.dosbatch',regex:'\\b(?:EQU|NEQ|LSS|LEQ|GTR|GEQ)\\b'},{token:['doc.comment','comment'],regex:'(?:^|\\b)(rem)($|\\s.*$)',caseInsensitive:true},{token:'comment.line.colons.dosbatch',regex:'::.*$'},{include:'variable'},{token:'punctuation.definition.string.begin.shell',regex:'"',push:[{token:'punctuation.definition.string.end.shell',regex:'"',next:'pop'},{include:'variable'},{defaultToken:'string.quoted.double.dosbatch'}]},{token:'keyword.operator.pipe.dosbatch',regex:'[|]'},{token:'keyword.operator.redirect.shell',regex:'&>|\\d*>&\\d*|\\d*(?:>>|>|<)|\\d*<&|\\d*<>'}],variable:[{token:'constant.numeric',regex:'%%\\w+|%[*\\d]|%\\w+%'},{token:'constant.numeric',regex:'%~\\d+'},{token:['markup.list','constant.other','markup.list'],regex:'(%)(\\w+)(%?)'}]};this.normalizeRules();};B.metaData={name:'Batch File',scopeName:'source.dosbatch',fileTypes:['bat']};o.inherits(B,T);e.BatchFileHighlightRules=B;});ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(r,e,a){"use strict";var o=r("../../lib/oop");var R=r("../../range").Range;var B=r("./fold_mode").FoldMode;var F=e.FoldMode=function(c){if(c){this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+c.start));this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+c.end));}};o.inherits(F,B);(function(){this.foldingStartMarker=/(\{|\[)[^\}\]]*$|^\s*(\/\*)/;this.foldingStopMarker=/^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/;this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/;this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/;this._getFoldWidgetBase=this.getFoldWidget;this.getFoldWidget=function(s,f,b){var l=s.getLine(b);if(this.singleLineBlockCommentRe.test(l)){if(!this.startRegionRe.test(l)&&!this.tripleStarBlockCommentRe.test(l))return"";}var c=this._getFoldWidgetBase(s,f,b);if(!c&&this.startRegionRe.test(l))return"start";return c;};this.getFoldWidgetRange=function(s,f,b,c){var l=s.getLine(b);if(this.startRegionRe.test(l))return this.getCommentRegionBlock(s,l,b);var m=l.match(this.foldingStartMarker);if(m){var i=m.index;if(m[1])return this.openingBracketBlock(s,m[1],b,i);var d=s.getCommentFoldRange(b,i+m[0].length,1);if(d&&!d.isMultiLine()){if(c){d=this.getSectionRange(s,b);}else if(f!="all")d=null;}return d;}if(f==="markbegin")return;var m=l.match(this.foldingStopMarker);if(m){var i=m.index+m[0].length;if(m[1])return this.closingBracketBlock(s,m[1],b,i);return s.getCommentFoldRange(b,i,-1);}};this.getSectionRange=function(s,b){var l=s.getLine(b);var c=l.search(/\S/);var d=b;var f=l.length;b=b+1;var g=b;var m=s.getLength();while(++bi)break;var h=this.getFoldWidgetRange(s,"all",b);if(h){if(h.start.row<=d){break;}else if(h.isMultiLine()){b=h.end.row;}else if(c==i){break;}}g=b;}return new R(d,f,g,s.getLine(g).length);};this.getCommentRegionBlock=function(s,l,b){var c=l.search(/\s*$/);var d=s.getLength();var f=b;var g=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;var h=1;while(++bf){return new R(f,c,i,l.length);}};}).call(F.prototype);});ace.define("ace/mode/batchfile",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/batchfile_highlight_rules","ace/mode/folding/cstyle"],function(r,e,m){"use strict";var o=r("../lib/oop");var T=r("./text").Mode;var B=r("./batchfile_highlight_rules").BatchFileHighlightRules;var F=r("./folding/cstyle").FoldMode;var M=function(){this.HighlightRules=B;this.foldingRules=new F();this.$behaviour=this.$defaultBehaviour;};o.inherits(M,T);(function(){this.lineCommentStart="::";this.blockComment="";this.$id="ace/mode/batchfile";}).call(M.prototype);e.Mode=M;});