]> iEval git - gruntmaster-page.git/blame - js/90-divine-format.js
Change js mtime test
[gruntmaster-page.git] / js / 90-divine-format.js
CommitLineData
502d9da0
MG
1var ext_table = {
2 'c' : 'C',
3
4 'cc' : 'CPP',
5 'cpp' : 'CPP',
6 'cxx' : 'CPP',
7 'C' : 'CPP',
8
9 'go' : 'GOLANG',
10
11 'gs' : 'GOLFSCRIPT',
12
13 'hs' : 'HASKELL',
14 'lhs' : 'HASKELL',
15
16 'lisp': 'SBCL',
17 'lsp' : 'SBCL',
18 'cl' : 'SBCL',
19 'l' : 'SBCL',
20
21 'java': 'JAVA',
22
23 'pas' : 'PASCAL',
24
25 'pl' : 'PERL',
26
27 'py' : 'PYTHON',
28
29 'rb' : 'RUBY'
30}
31
7093e9ba
MG
32function divine_format() {
33 var filename = $('#prog')[0].value;
34 var ext = /\.([^.]*)$/.exec(filename)[1];
502d9da0
MG
35
36 if(ext_table[ext])
37 $('#prog_format')[0].value = ext_table[ext];
7093e9ba
MG
38}
39
8345760a 40$(() => $('#prog').on('change', divine_format));
This page took 0.02593 seconds and 4 git commands to generate.