tartrazine/common.go

814 lines
30 KiB
Go
Raw Normal View History

2016-07-13 17:05:09 +00:00
package slinguist
// Extracted from github/linguist.
// This one-liner prints the latest version:
// curl https://raw.githubusercontent.com/github/linguist/master/lib/linguist/languages.yml | python -c 'from collections import defaultdict; import os; import json; import yaml; l = yaml.load(os.sys.stdin.read()); exts = reduce(lambda acc, x: acc + x, [v.get("extensions", []) for k, v in l.items()], []); m = {ext: [k for k, v in l.items() if ext in v.get("extensions", [])] for ext in exts}; print "package utils\n\nvar LanguagesByExtension = map[string][]string{\n"+ json.dumps(m).replace("]", "}").replace("},", "},\n").replace("[", "{")[1:-1] + ",\n}\n"' | gofmt
var LanguagesByExtension = map[string][]string{
".1": {"Groff"},
".2": {"Groff"},
".3": {"Groff"},
".4": {"Groff"},
".4th": {"Forth"},
".5": {"Groff"},
".6": {"Groff"},
".6pl": {"Perl6"},
".6pm": {"Perl6"},
".7": {"Groff"},
"._coffee": {"CoffeeScript"},
"._js": {"JavaScript"},
"._ls": {"LiveScript"},
".a51": {"Assembly"},
".abap": {"ABAP"},
".ada": {"Ada"},
".adb": {"Ada"},
".ado": {"Stata"},
".adoc": {"AsciiDoc"},
".adp": {"Tcl"},
".ads": {"Ada"},
".agda": {"Agda"},
".ahk": {"AutoHotkey"},
".ahkl": {"AutoHotkey"},
".aj": {"AspectJ"},
".als": {"Alloy"},
".ant": {"XML"},
".apacheconf": {"ApacheConf"},
".apl": {"APL"},
".applescript": {"AppleScript"},
".arc": {"Arc"},
".as": {"ActionScript"},
".asax": {"ASP"},
".asc": {"Public Key", "AsciiDoc", "AGS Script"},
".asciidoc": {"AsciiDoc"},
".ascx": {"ASP"},
".asd": {"Common Lisp"},
".ash": {"AGS Script"},
".ashx": {"ASP"},
".ASM": {"Assembly"},
".asm": {"Assembly"},
".asmx": {"ASP"},
".asp": {"ASP"},
".aspx": {"ASP"},
".au3": {"AutoIt"},
".aug": {"Augeas"},
".auk": {"Awk"},
".aux": {"TeX"},
".aw": {"PHP"},
".awk": {"Awk"},
".axd": {"ASP"},
".axml": {"XML"},
".b": {"Brainfuck"},
".bas": {"Visual Basic"},
".bash": {"Shell"},
".bat": {"Batchfile"},
".bats": {"Shell"},
".bb": {"BitBake", "BlitzBasic"},
".bbx": {"TeX"},
".befunge": {"Befunge"},
".bf": {"Brainfuck"},
".bib": {"TeX"},
".bmx": {"BlitzMax"},
".bones": {"JavaScript"},
".boo": {"Boo"},
".brd": {"Eagle"},
".bro": {"Bro"},
".brs": {"Brightscript"},
".bsv": {"Bluespec"},
".builder": {"Ruby"},
".C": {"C"},
".c": {"C"},
".c++": {"C++"},
".c++-objdump": {"Cpp-ObjDump"},
".c++objdump": {"Cpp-ObjDump"},
".c-objdump": {"C-ObjDump"},
".capnp": {"Cap'n Proto"},
".cats": {"C"},
".cbl": {"COBOL"},
".cbx": {"TeX"},
".cc": {"C++"},
".ccp": {"COBOL"},
".ccxml": {"XML"},
".cdf": {"Mathematica"},
".ceylon": {"Ceylon"},
".cfc": {"ColdFusion CFC"},
".cfg": {"INI"},
".cfm": {"ColdFusion"},
".cfml": {"ColdFusion"},
".cgi": {"Python", "Shell", "Perl"},
".chpl": {"Chapel"},
".chs": {"C2hs Haskell"},
".cirru": {"Cirru"},
".cjsx": {"CoffeeScript"},
".ck": {"ChucK"},
".cl": {"Cool", "OpenCL", "Common Lisp"},
".cl2": {"Clojure"},
".clixml": {"XML"},
".clj": {"Clojure"},
".cljc": {"Clojure"},
".cljs": {"Clojure"},
".cljs.hl": {"Clojure"},
".cljscm": {"Clojure"},
".cljx": {"Clojure"},
".clp": {"CLIPS"},
".cls": {"Visual Basic", "Apex", "OpenEdge ABL", "TeX"},
".cmake": {"CMake"},
".cmake.in": {"CMake"},
".cmd": {"Batchfile"},
".cob": {"COBOL"},
".COB": {"COBOL"},
".cobol": {"COBOL"},
".coffee": {"CoffeeScript"},
".command": {"Shell"},
".conf": {"ApacheConf"},
".coq": {"Coq"},
".cp": {"Component Pascal", "C++"},
".cpp": {"C++"},
".cpp-objdump": {"Cpp-ObjDump"},
".cppobjdump": {"Cpp-ObjDump"},
".cproject": {"XML"},
".cps": {"Component Pascal"},
".cpy": {"COBOL"},
".CPY": {"COBOL"},
".cql": {"SQL"},
".cr": {"Crystal"},
".creole": {"Creole"},
".cs": {"C#", "Smalltalk"},
".csh": {"Tcsh"},
".cshtml": {"C#"},
".cson": {"CoffeeScript"},
".csproj": {"XML"},
".css": {"CSS"},
".csx": {"C#"},
".ct": {"XML"},
".ctp": {"PHP"},
".cu": {"Cuda"},
".cuh": {"Cuda"},
".cw": {"Redcode"},
".cxx": {"C++"},
".cxx-objdump": {"Cpp-ObjDump"},
".cy": {"Cycript"},
".d": {"D"},
".d-objdump": {"D-ObjDump"},
".darcspatch": {"Darcs Patch"},
".dart": {"Dart"},
".dats": {"ATS"},
".dcl": {"Clean"},
".ddl": {"SQL"},
".decls": {"BlitzBasic"},
".desktop": {"desktop"},
".desktop.in": {"desktop"},
".dfm": {"Pascal"},
".di": {"D"},
".diff": {"Diff"},
".dita": {"XML"},
".ditamap": {"XML"},
".ditaval": {"XML"},
".djs": {"Dogescript"},
".dll.config": {"XML"},
".dlm": {"IDL"},
".dm": {"DM"},
".do": {"Stata"},
".dockerfile": {"Dockerfile"},
".doh": {"Stata"},
".DOT": {"Graphviz (DOT)"},
".dot": {"Graphviz (DOT)"},
".dpatch": {"Darcs Patch"},
".dpr": {"Pascal"},
".druby": {"Mirah"},
".dtx": {"TeX"},
".duby": {"Mirah"},
".dyalog": {"APL"},
".dyl": {"Dylan"},
".dylan": {"Dylan"},
".E": {"E"},
".e": {"Eiffel"},
".ebuild": {"Gentoo Ebuild"},
".ec": {"eC"},
".ecl": {"Prolog", "ECL"},
".eclass": {"Gentoo Eclass"},
".eclxml": {"ECL"},
".edn": {"edn"},
".eh": {"eC"},
".el": {"Emacs Lisp"},
".eliom": {"OCaml"},
".eliomi": {"OCaml"},
".elm": {"Elm"},
".em": {"EmberScript"},
".emacs": {"Emacs Lisp"},
".emacs.desktop": {"Emacs Lisp"},
".emberscript": {"EmberScript"},
".epj": {"Ecere Projects"},
".eps": {"PostScript"},
".erb": {"HTML+ERB"},
".erb.deface": {"HTML+ERB"},
".erl": {"Erlang"},
".es": {"Erlang"},
".es6": {"JavaScript"},
".escript": {"Erlang"},
".ex": {"Elixir"},
".exs": {"Elixir"},
".F": {"Forth", "FORTRAN"},
".f": {"Forth", "FORTRAN"},
".f03": {"FORTRAN"},
".F03": {"FORTRAN"},
".f08": {"FORTRAN"},
".F08": {"FORTRAN"},
".F77": {"FORTRAN"},
".f77": {"FORTRAN"},
".f90": {"FORTRAN"},
".F90": {"FORTRAN"},
".F95": {"FORTRAN"},
".f95": {"FORTRAN"},
".factor": {"Factor"},
".fan": {"Fantom"},
".fancypack": {"Fancy"},
".fcgi": {"PHP", "Python", "Shell", "Perl", "Ruby", "Lua"},
".feature": {"Cucumber"},
".filters": {"XML"},
".fish": {"fish"},
".flux": {"FLUX"},
".for": {"Forth", "FORTRAN"},
".FOR": {"FORTRAN"},
".forth": {"Forth"},
".fp": {"GLSL"},
".FPP": {"FORTRAN"},
".fpp": {"FORTRAN"},
".fr": {"Forth", "Text", "Frege"},
".frag": {"GLSL", "JavaScript"},
".frg": {"GLSL"},
".frm": {"Visual Basic"},
".frt": {"Forth"},
".frx": {"Visual Basic"},
".fs": {"GLSL", "Forth", "F#"},
".fshader": {"GLSL"},
".fsi": {"F#"},
".fsproj": {"XML"},
".fsx": {"F#"},
".fth": {"Forth"},
".fun": {"Standard ML"},
".fx": {"FLUX"},
".fxml": {"XML"},
".fy": {"Fancy"},
".g": {"G-code", "GAP"},
".g4": {"ANTLR"},
".gap": {"GAP"},
".gawk": {"Awk"},
".gco": {"G-code"},
".gcode": {"G-code"},
".gd": {"GAP", "GDScript"},
".gemspec": {"Ruby"},
".geo": {"GLSL"},
".geom": {"GLSL"},
".gf": {"Grammatical Framework"},
".gi": {"GAP"},
".glade": {"XML"},
".glf": {"Glyph"},
".glsl": {"GLSL"},
".glslv": {"GLSL"},
".gml": {"Graph Modeling Language", "Game Maker Language"},
".gms": {"GAMS"},
".gnu": {"Gnuplot"},
".gnuplot": {"Gnuplot"},
".go": {"Go"},
".god": {"Ruby"},
".golo": {"Golo"},
".gp": {"Gnuplot"},
".grace": {"Grace"},
".gradle": {"Gradle"},
".groovy": {"Groovy"},
".grt": {"Groovy"},
".grxml": {"XML"},
".gs": {"Gosu", "JavaScript"},
".gshader": {"GLSL"},
".gsp": {"Groovy Server Pages"},
".gst": {"Gosu"},
".gsx": {"Gosu"},
".gtpl": {"Groovy"},
".gv": {"Graphviz (DOT)"},
".gvy": {"Groovy"},
".gyp": {"Python"},
".H": {"C"},
".h": {"C", "C++", "Objective-C"},
".h++": {"C++"},
".haml": {"Haml"},
".haml.deface": {"Haml"},
".handlebars": {"Handlebars"},
".hats": {"ATS"},
".hb": {"Harbour"},
".hbs": {"Handlebars"},
".hh": {"Hack", "C++"},
".hic": {"Clojure"},
".hpp": {"C++"},
".hqf": {"SQF"},
".hrl": {"Erlang"},
".hs": {"Haskell"},
".hsc": {"Haskell"},
".htm": {"HTML"},
".html": {"HTML"},
".html.hl": {"HTML"},
".http": {"HTTP"},
".hx": {"Haxe"},
".hxsl": {"Haxe"},
".hxx": {"C++"},
".hy": {"Hy"},
".i7x": {"Inform 7"},
".iced": {"CoffeeScript"},
".icl": {"Clean"},
".idc": {"C"},
".idr": {"Idris"},
".ihlp": {"Stata"},
".ijs": {"J"},
".ik": {"Ioke"},
".ily": {"LilyPond"},
".ini": {"INI"},
".inl": {"C++"},
".ino": {"Arduino"},
".ins": {"TeX"},
".intr": {"Dylan"},
".io": {"Io"},
".ipf": {"IGOR Pro"},
".ipp": {"C++"},
".irbrc": {"Ruby"},
".irclog": {"IRC log"},
".iss": {"Inno Setup"},
".ivy": {"XML"},
".j": {"Objective-J", "Jasmin"},
".jade": {"Jade"},
".jake": {"JavaScript"},
".java": {"Java"},
".jelly": {"XML"},
".jinja": {"HTML+Django"},
".jl": {"Julia"},
".jq": {"JSONiq"},
".js": {"JavaScript"},
".jsb": {"JavaScript"},
".jsfl": {"JavaScript"},
".jsm": {"JavaScript"},
".json": {"JSON"},
".json5": {"JSON5"},
".jsonld": {"JSONLD"},
".jsp": {"Java Server Pages"},
".jss": {"JavaScript"},
".jsx": {"JavaScript"},
".kid": {"Genshi"},
".kit": {"Kit"},
".kml": {"XML"},
".krl": {"KRL"},
".ksh": {"Shell"},
".kt": {"Kotlin"},
".ktm": {"Kotlin"},
".kts": {"Kotlin"},
".lagda": {"Literate Agda"},
".las": {"Lasso"},
".lasso": {"Lasso"},
".lasso8": {"Lasso"},
".lasso9": {"Lasso"},
".latte": {"Latte"},
".launch": {"XML"},
".lbx": {"TeX"},
".ldml": {"Lasso"},
".less": {"Less"},
".lfe": {"LFE"},
".lgt": {"Logtalk"},
".lhs": {"Literate Haskell"},
".lid": {"Dylan"},
".lidr": {"Idris"},
".liquid": {"Liquid"},
".lisp": {"NewLisp", "Common Lisp"},
".litcoffee": {"Literate CoffeeScript"},
".ll": {"LLVM"},
".lmi": {"Python"},
".lock": {"JSON"},
".logtalk": {"Logtalk"},
".lol": {"LOLCODE"},
".lookml": {"LookML"},
".lpr": {"Pascal"},
".ls": {"LoomScript", "LiveScript"},
".lsl": {"LSL"},
".lsp": {"NewLisp", "Common Lisp"},
".ltx": {"TeX"},
".lua": {"Lua"},
".lvproj": {"LabVIEW"},
".ly": {"LilyPond"},
".m": {"Objective-C", "Mercury", "M", "Mathematica", "Matlab"},
".ma": {"Mathematica"},
".mak": {"Makefile"},
".mako": {"Mako"},
".man": {"Groff"},
".mao": {"Mako"},
".markdown": {"Markdown"},
".mask": {"Mask"},
".mata": {"Stata"},
".matah": {"Stata"},
".mathematica": {"Mathematica"},
".matlab": {"Matlab"},
".mawk": {"Awk"},
".maxhelp": {"Max"},
".maxpat": {"Max"},
".maxproj": {"Max"},
".md": {"Markdown"},
".mediawiki": {"MediaWiki"},
".minid": {"MiniD"},
".mir": {"Mirah"},
".mirah": {"Mirah"},
".mk": {"Makefile"},
".mkd": {"Markdown"},
".mkdn": {"Markdown"},
".mkdown": {"Markdown"},
".mkii": {"TeX"},
".mkiv": {"TeX"},
".mkvi": {"TeX"},
".ml": {"OCaml"},
".ML": {"Standard ML"},
".ml4": {"OCaml"},
".mli": {"OCaml"},
".mll": {"OCaml"},
".mly": {"OCaml"},
".mm": {"Objective-C++", "XML"},
".mo": {"Modelica"},
".monkey": {"Monkey"},
".moo": {"Mercury", "Moocode"},
".moon": {"MoonScript"},
".mspec": {"Ruby"},
".mss": {"CartoCSS"},
".mtml": {"MTML"},
".mu": {"mupad"},
".mumps": {"M"},
".mustache": {"HTML+Django"},
".mxml": {"XML"},
".mxt": {"Max"},
".myt": {"Myghty"},
".n": {"Nemerle"},
".nawk": {"Awk"},
".nb": {"Mathematica"},
".nbp": {"Mathematica"},
".nc": {"nesC"},
".nginxconf": {"Nginx"},
".ni": {"Inform 7"},
".nim": {"Nimrod"},
".nimrod": {"Nimrod"},
".ninja": {"Ninja"},
".nit": {"Nit"},
".nix": {"Nix"},
".njs": {"JavaScript"},
".nl": {"NewLisp"},
".nlogo": {"NetLogo"},
".nproj": {"XML"},
".nqp": {"Perl6"},
".nse": {"Lua"},
".nsh": {"NSIS"},
".nsi": {"NSIS"},
".nu": {"Nu"},
".numpy": {"NumPy"},
".numpyw": {"NumPy"},
".numsc": {"NumPy"},
".nuspec": {"XML"},
".nut": {"Squirrel"},
".ny": {"Common Lisp"},
".objdump": {"ObjDump"},
".omgrofl": {"Omgrofl"},
".ooc": {"ooc"},
".opa": {"Opa"},
".opal": {"Opal"},
".opencl": {"OpenCL"},
".org": {"Org"},
".osm": {"XML"},
".owl": {"Web Ontology Language"},
".ox": {"Ox"},
".oxh": {"Ox"},
".oxo": {"Ox"},
".oxygene": {"Oxygene"},
".oz": {"Oz"},
".p": {"OpenEdge ABL"},
".p6": {"Perl6"},
".p6l": {"Perl6"},
".p6m": {"Perl6"},
".pac": {"JavaScript"},
".pan": {"Pan"},
".parrot": {"Parrot"},
".pas": {"Pascal"},
".pasm": {"Parrot Assembly"},
".pat": {"Max"},
".patch": {"Diff"},
".pb": {"PureBasic"},
".pbi": {"PureBasic"},
".pd": {"Pure Data"},
".pd_lua": {"Lua"},
".pde": {"Processing"},
".perl": {"Perl"},
".ph": {"Perl"},
".php": {"PHP", "Hack"},
".php3": {"PHP"},
".php4": {"PHP"},
".php5": {"PHP"},
".phpt": {"PHP"},
".phtml": {"HTML+PHP"},
".pig": {"PigLatin"},
".pike": {"Pike"},
".pir": {"Parrot Internal Representation"},
".PL": {"Perl"},
".pl": {"Perl6", "Perl", "Prolog"},
".pl6": {"Perl6"},
".plist": {"XML"},
".plot": {"Gnuplot"},
".plt": {"Gnuplot"},
".pluginspec": {"XML", "Ruby"},
".plx": {"Perl"},
".pm": {"Perl6", "Perl"},
".pm6": {"Perl6"},
".pmod": {"Pike"},
".po": {"Gettext Catalog"},
".pod": {"Perl", "Pod"},
".podsl": {"Common Lisp"},
".podspec": {"Ruby"},
".pogo": {"PogoScript"},
".pot": {"Gettext Catalog"},
".pp": {"Pascal", "Puppet"},
".prc": {"SQL"},
".prefs": {"INI"},
".prg": {"xBase"},
".pri": {"QMake"},
".pro": {"QMake", "Prolog", "IDL"},
".prolog": {"Prolog"},
".properties": {"INI"},
".proto": {"Protocol Buffer"},
".ps": {"PostScript"},
".ps1": {"PowerShell"},
".ps1xml": {"XML"},
".psc": {"Papyrus"},
".psc1": {"XML"},
".psd1": {"PowerShell"},
".psgi": {"Perl"},
".psm1": {"PowerShell"},
".pt": {"XML"},
".pub": {"Public Key"},
".purs": {"PureScript"},
".pwn": {"PAWN"},
".pxd": {"Cython"},
".pxi": {"Cython"},
".py": {"Python"},
".pyde": {"Python"},
".pyp": {"Python"},
".pyt": {"Python"},
".pytb": {"Python traceback"},
".pyw": {"Python"},
".pyx": {"Cython"},
".qml": {"QML"},
".R": {"R"},
".r": {"Rebol", "R"},
".r2": {"Rebol"},
".r3": {"Rebol"},
".rabl": {"Ruby"},
".rake": {"Ruby"},
".raml": {"RAML"},
".raw": {"Raw token data"},
".rb": {"Ruby"},
".rbbas": {"REALbasic"},
".rbfrm": {"REALbasic"},
".rbmnu": {"REALbasic"},
".rbres": {"REALbasic"},
".rbtbar": {"REALbasic"},
".rbuild": {"Ruby"},
".rbuistate": {"REALbasic"},
".rbw": {"Ruby"},
".rbx": {"Ruby"},
".rbxs": {"Lua"},
".rd": {"R"},
".Rd": {"R"},
".rdf": {"XML"},
".rdoc": {"RDoc"},
".reb": {"Rebol"},
".rebol": {"Rebol"},
".red": {"Red"},
".reds": {"Red"},
".reek": {"YAML"},
".rest": {"reStructuredText"},
".rg": {"Rouge"},
".rhtml": {"RHTML"},
".rkt": {"Racket"},
".rktd": {"Racket"},
".rktl": {"Racket"},
".rl": {"Ragel in Ruby Host"},
".Rmd": {"RMarkdown"},
".rmd": {"RMarkdown"},
".robot": {"RobotFramework"},
".ron": {"Markdown"},
".rq": {"SPARQL"},
".rs": {"Rust"},
".rss": {"XML"},
".rst": {"reStructuredText"},
".rsx": {"R"},
".ru": {"Ruby"},
".rviz": {"YAML"},
".S": {"GAS"},
".s": {"GAS"},
".sage": {"Sage"},
".sagews": {"Sage"},
".sas": {"SAS"},
".sass": {"Sass"},
".sats": {"ATS"},
".sbt": {"Scala"},
".sc": {"SuperCollider", "Scala"},
".scad": {"OpenSCAD"},
".scala": {"Scala"},
".scaml": {"Scaml"},
".scd": {"SuperCollider"},
".sce": {"Scilab"},
".sch": {"Eagle"},
".sci": {"Scilab"},
".scm": {"Scheme"},
".scpt": {"AppleScript"},
".scrbl": {"Racket"},
".scss": {"SCSS"},
".scxml": {"XML"},
".self": {"Self"},
".sh": {"Shell"},
".sh-session": {"ShellSession"},
".shader": {"GLSL"},
".shen": {"Shen"},
".sig": {"Standard ML"},
".sj": {"Objective-J"},
".sjs": {"JavaScript"},
".sl": {"Slash"},
".sld": {"Scheme"},
".slim": {"Slim"},
".sls": {"Scheme", "SaltStack"},
".sml": {"Standard ML"},
".sp": {"SourcePawn"},
".sparql": {"SPARQL"},
".spin": {"Propeller Spin"},
".sps": {"Scheme"},
".sqf": {"SQF"},
".sql": {"SQL"},
".srdf": {"XML"},
".ss": {"Scheme"},
".ssjs": {"JavaScript"},
".st": {"HTML", "Smalltalk"},
".sthlp": {"Stata"},
".ston": {"STON"},
".stTheme": {"XML"},
".sty": {"TeX"},
".styl": {"Stylus"},
".sublime-build": {"JavaScript"},
".sublime-commands": {"JavaScript"},
".sublime-completions": {"JavaScript"},
".sublime-keymap": {"JavaScript"},
".sublime-macro": {"JavaScript"},
".sublime-menu": {"JavaScript"},
".sublime-mousemap": {"JavaScript"},
".sublime-project": {"JavaScript"},
".sublime-settings": {"JavaScript"},
".sublime-snippet": {"XML"},
".sublime-theme": {"JavaScript"},
".sublime-workspace": {"JavaScript"},
".sublime_metrics": {"JavaScript"},
".sublime_session": {"JavaScript"},
".sv": {"SystemVerilog"},
".svg": {"XML"},
".svh": {"SystemVerilog"},
".swift": {"Swift"},
".t": {"Perl6", "Turing", "Perl"},
".tab": {"SQL"},
".tac": {"Python"},
".targets": {"XML"},
".tcc": {"C++"},
".tcl": {"Tcl"},
".tcsh": {"Tcsh"},
".tea": {"Tea"},
".tex": {"TeX"},
".textile": {"Textile"},
".thor": {"Ruby"},
".thrift": {"Thrift"},
".thy": {"Isabelle"},
".tm": {"Tcl"},
".tmCommand": {"XML"},
".tml": {"XML"},
".tmLanguage": {"XML"},
".tmPreferences": {"XML"},
".tmSnippet": {"XML"},
".tmTheme": {"XML"},
".tmux": {"Shell"},
".toc": {"TeX"},
".toml": {"TOML"},
".tpl": {"Smarty"},
".tpp": {"C++"},
".ts": {"XML", "TypeScript"},
".tst": {"Scilab", "GAP"},
".ttl": {"Turtle"},
".tu": {"Turing"},
".twig": {"Twig"},
".txl": {"TXL"},
".txt": {"Text"},
".uc": {"UnrealScript"},
".udf": {"SQL"},
".ui": {"XML"},
".upc": {"Unified Parallel C"},
".urdf": {"XML"},
".v": {"Verilog", "Coq"},
".vala": {"Vala"},
".vapi": {"Vala"},
".vark": {"Gosu"},
".vb": {"Visual Basic"},
".vba": {"Visual Basic"},
".vbhtml": {"Visual Basic"},
".vbproj": {"XML"},
".vbs": {"Visual Basic"},
".vcl": {"VCL"},
".vcxproj": {"XML"},
".veo": {"Verilog"},
".vert": {"GLSL"},
".vh": {"SystemVerilog"},
".vhd": {"VHDL"},
".vhdl": {"VHDL"},
".vhf": {"VHDL"},
".vhi": {"VHDL"},
".vho": {"VHDL"},
".vhs": {"VHDL"},
".vht": {"VHDL"},
".vhw": {"VHDL"},
".vim": {"VimL"},
".viw": {"SQL"},
".volt": {"Volt"},
".vrx": {"GLSL"},
".vshader": {"GLSL"},
".vxml": {"XML"},
".w": {"C"},
".watchr": {"Ruby"},
".webidl": {"WebIDL"},
".weechatlog": {"IRC log"},
".wisp": {"wisp"},
".wlua": {"Lua"},
".wsdl": {"XML"},
".wsf": {"XML"},
".wsgi": {"Python"},
".wxi": {"XML"},
".wxl": {"XML"},
".wxs": {"XML"},
".x": {"Logos"},
".x3d": {"XML"},
".xacro": {"XML"},
".xaml": {"XML"},
".xc": {"XC"},
".xht": {"HTML"},
".xhtml": {"HTML"},
".xi": {"Logos"},
".xlf": {"XML"},
".xliff": {"XML"},
".xm": {"Logos"},
".xmi": {"XML"},
".xml": {"XML"},
".xml.dist": {"XML"},
".xojo_code": {"Xojo"},
".xojo_menu": {"Xojo"},
".xojo_report": {"Xojo"},
".xojo_script": {"Xojo"},
".xojo_toolbar": {"Xojo"},
".xojo_window": {"Xojo"},
".xpl": {"XProc"},
".xproc": {"XProc"},
".xpy": {"Python"},
".xq": {"XQuery"},
".xql": {"XQuery"},
".xqm": {"XQuery"},
".xquery": {"XQuery"},
".xqy": {"XQuery"},
".xs": {"XS"},
".xsd": {"XML"},
".xsjs": {"JavaScript"},
".xsjslib": {"JavaScript"},
".xsl": {"XSLT"},
".xslt": {"XSLT"},
".xtend": {"Xtend"},
".xul": {"XML"},
".y": {"Bison"},
".yaml": {"YAML"},
".yml": {"YAML"},
".zcml": {"XML"},
".zep": {"Zephir"},
".zimpl": {"Zimpl"},
".zmpl": {"Zimpl"},
".zpl": {"Zimpl"},
".zsh": {"Shell"},
}
func init() {
ExtensionsByLanguage = reverseStringListMap(LanguagesByExtension)
}
var ExtensionsByLanguage map[string][]string
func GetLanguageExtensions(language string) []string {
return ExtensionsByLanguage[language]
}
const OtherLanguage = "Other"
func reverseStringListMap(input map[string][]string) (output map[string][]string) {
output = map[string][]string{}
for key, set := range input {
for _, value := range set {
output[value] = append(output[value], key)
}
}
return
}