-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathsrc.tmLanguage
More file actions
210 lines (210 loc) · 7.79 KB
/
src.tmLanguage
File metadata and controls
210 lines (210 loc) · 7.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
{ patterns = (
{ include = '#application_call'; },
{ include = '#function_call'; },
{ include = '#arg_call'; },
{ include = '#Comment'; },
{ include = '#String'; },
{ include = '#Expression'; },
{ name = 'punctuation.section.parens.begin';
begin = '^\s*\[';
end = '\]';
contentName = 'support.class.name';
},
{ name = 'keyword.operator.assignment';
match = '\=>?';
},
);
repository = {
Comment = {
name = 'comment.line';
begin = ';';
end = '$';
};
Expression = {
begin = '\$(\[)';
end = '\]';
beginCaptures = {
0 = { name = 'keyword.other'; };
1 = { name = 'punctuation.section.expression.begin'; };
};
endCaptures = {
0 = { name = 'keyword.other'; };
1 = { name = 'punctuation.secion.expression.end'; };
};
patterns = (
{ include = '#function_call'; },
{ include = '#application_call'; },
{ include = '#Variable'; },
{ include = '#String'; },
{ include = '$self'; },
{
name='variable.parameter';
match='[^{}()[]]+';
}
);
};
String = {
name = 'string.quoted.double';
begin = '"';
end = '"';
beginCaptures = { 0 = { name = 'punctuation.definition.string.begin'; }; };
endCaptures = { 0 = { name = 'punctuation.definition.string.end'; }; };
patterns = (
{ include = '#function_call'; },
{ include = '#application_call'; },
{ include = '#Variable'; },
{ include = '#Expression'; },
);
};
Variable = {
begin = '\$({)';
end = '(})';
beginCaptures = {
0 = { name = 'constant.numeric.integer'; };
1 = { name = 'punctuation.section.begin.variable'; };
};
endCaptures = {
0 = { name = 'constant.numeric.integer'; };
1 = { name = 'punctuation.section.variable.end'; };
};
patterns = (
{ include = '#function_call'; },
{ include = '#application_call'; },
{ include = '#self'; },
{
name='variable.parameter';
match='[^{}()[]]+';
}
);
};
application_call = {
patterns = (
{ name = 'meta.application-call';
begin = '(?xi)
(\.)?
\b(
absolutetimeout | addqueuemember | adsiprog | agentcallbacklogin | agentlogin |
agentmonitoroutgoing | agi | alarmreceiver | alsamonitor | amd | answer |
appendcdruserfield | asteriskcmgnbscat | authenticate | background | backgrounddetect |
bridge | busy | callerid | callingpres | changemonitor | chanisavail | channelredirect |
chanspy | checkgroup | confbridge | congestion | controlplayback | dbdel | dbdeltree |
dbquery | dbrewrite | deadagi | dial | dictate | digittimeout | directory | disa |
dtmftotext | dundilookup | eagi | echo | endwhile | enumlookup | execif | extenspy |
festival | flash | flite | forkcdr | getcpeid | getgroupcount | getgroupmatchcount |
gosub | gosubif | goto | gotoif | gotoiftime | hangup | hasnewvoicemail | hasvoicemail |
ices | importvar | jabbersend | jabberstatus | lookupblacklist | lookupcidname | macro |
macroexclusive | macroexit | mailboxexists | meetme | meetmeadmin | meetmecount |
milliwatt | minivm | mixmonitor | monitor | mp3player | musiconhold | mysql | nocdr |
noop | page | parkandannounce | parkedcall | pausequeuemember | perl | pickup | pickup |
playback | playtones | pppd | privacymanager | progress | queue | read | realtime |
record | removequeuemember | resetcdr | responsetimeout | retrydial | return | ringing |
rpt | sayalpha | saydigits | saynumber | sayphonetic | sayunixtime | senddtmf |
sendimage | sendtext | sendurl | set | setaccount | setamaflags | setcallerid |
setcallerpres | setcdruserfield | setglobalvar | setvar | sipaddheader | sipcallpickup |
sipdtmfmode | sipgetheader | sms | softhangup | srxdeflect | srxechocan | srxmwi |
stackpop | steal | stopmixmonitor | stopmonitor | stopplaytones | system | testclient |
testserver | transfer | trysystem | txtcidname | unpausequeuemember | userevent |
verbose | vmauthenticate | voicemail | voicemail | voicemailmain | wait | waitexten |
waitforring | waitmusiconhold | while | zapateller | zapbarge | zapras| zapscan |
zapsendkeypadfacility
)
\s*(?=(\())';
end = '(\))';
beginCaptures = {
2 = { name = 'entity.name.function'; };
4 = { name = 'punctuation.definition.arguments.begin'; };
};
endCaptures = { 1 = { name = 'punctuation.definition.arguments.end'; }; };
patterns = (
{ begin = '(\()';
end = '(?=\))';
beginCaptures = { 1 = { name = 'punctuation.definition.arguments.begin'; }; };
contentName = 'meta.function-call.arguments';
patterns = (
{ include = '#function_call'; },
{ include = '#Expression'; },
{ include = '#Variable'; },
{ include = '#String'; },
{ include = '$self'; },
);
},
);
},
);
};
arg_call = {
patterns = (
{ name = 'meta.arg-call';
begin = '(?xi)\b(\d)\s*(?=(\())';
end = '(\))';
beginCaptures = {
1 = { name = 'support.function.magic.call'; };
3 = { name = 'punctuation.definition.arguments.begin'; };
};
endCaptures = { 1 = { name = 'punctuation.definition.arguments.end'; }; };
patterns = (
{ begin = '(\()';
end = '(?=\))';
beginCaptures = { 1 = { name = 'punctuation.definition.arguments.begin'; }; };
contentName = 'meta.function-call.arguments';
patterns = (
{ include = '#application_call'; },
{ include = '#Expression'; },
{ include = '#Variable'; },
{ include = '#String'; },
{ include = '$self'; },
);
},
);
},
);
};
function_call = {
patterns = (
{ name = 'meta.function-call';
begin = '(?xi)
(\.)?
\b(
aes_decrypt | aes_encrypt | agc | agent | array | ast_config | audiohook_inherit |
base64_decode | base64_encode | blacklist | callerid | callerpres | cdr |
channel | channels | check_md5 | checksipdomain | clearhash | confbridge |
confbridge_info | connectedline | csv_quote | curl | curlopt | cut | db |
db_delete | db_exists | dec | denoise | device_state | dialgroup |
dialplan_exists | dundilookup | dundiquery | dundiresult | enumlookup |
enumquery | enumresult | env | eval | exception | exists | extension_state |
fieldqty | file | filter | getcodec | group | group_count | group_list |
group_match_count | hash | hashkeys | hint | iaxchaninfo | iaxpeer | iaxvar | if |
ifmodule | iftime | import | inc | isnull | jack_hook | keypadhash | language |
len | local | lock | math | md5 | musicclass | odbc | queue_member_count |
queue_member_list | queue_waiting_count | queueagentcount | quote | rand |
realtime | regex | replace | set | sha1 | shared | shell | sip_header |
sipaddheader | sipchaninfo | sippeer | sort | sql_esc | stat | strftime |
strptime | sysinfo | timeout | tolower | toupper | trylock | txtcidname | unlock |
uridecode | uriencode | vmcount | volume
)
\s*(?=(\())';
end = '(\))';
beginCaptures = {
2 = { name = 'entity.name.function'; };
4 = { name = 'punctuation.definition.arguments.begin'; };
};
endCaptures = { 1 = { name = 'punctuation.definition.arguments.end'; }; };
patterns = (
{ begin = '(\()';
end = '(?=\))';
beginCaptures = { 1 = { name = 'punctuation.definition.arguments.begin'; }; };
contentName = 'meta.function-call.arguments';
patterns = (
{ include = '#application_call'; },
{ include = '#Expression'; },
{ include = '#Variable'; },
{ include = '#String'; },
{ include = '$self'; },
);
},
);
},
);
};
};
}t