Open tconbeer opened 1 year ago
Mapping of file extensions to Pygments short names; will need to be cleaned for "None"
and remove the *.
prefix. (and maybe deduped?)
{
"*.abap": "abap","*.ABAP": "abap",
"*.as": "actionscript",
"*.as": "actionscript3",
"*.adb": "ada","*.ads": "ada","*.ada": "ada",
"*.G": "antlr-objc","*.g": "antlr-objc",
"*.apl": "apl","*.aplf": "apl","*.aplo": "apl","*.apln": "apl","*.aplc": "apl","*.apli": "apl","*.dyalog": "apl",
"*.applescript": "applescript",
"*.ahk": "autohotkey","*.ahkl": "autohotkey",
"*.au3": "autoit",
"None": "basemake",
"*.sh": "bash","*.ksh": "bash","*.bash": "bash","*.ebuild": "bash","*.eclass": "bash","*.exheres-0": "bash","*.exlib": "bash","*.zsh": "bash",".bashrc": "bash","bashrc": "bash",".bash\*": "bash","bash\*": "bash","zshrc": "bash",".zshrc": "bash",".kshrc": "bash","kshrc": "bash","PKGBUILD": "bash",
"*.bat": "batch","*.cmd": "batch",
"*.bbc": "bbcbasic",
"*.bb": "blitzbasic","*.decls": "blitzbasic",
"*.boo": "boo",
"*.c": "c","*.h": "c","*.idc": "c","*.x[bp]m": "c",
"*.cs": "csharp",
"*.cpp": "cpp","*.hpp": "cpp","*.c++": "cpp","*.h++": "cpp","*.cc": "cpp","*.hh": "cpp","*.cxx": "cpp","*.hxx": "cpp","*.C": "cpp","*.H": "cpp","*.cp": "cpp","*.CPP": "cpp","*.tpp": "cpp",
"*.bas": "cbmbas",
"*.clj": "clojure","*.cljc": "clojure",
"*.cljs": "clojurescript",
"*.cmake": "cmake","CMakeLists.txt": "cmake",
"*.cob": "cobol","*.COB": "cobol","*.cpy": "cobol","*.CPY": "cobol",
"*.cbl": "cobolfree","*.CBL": "cobolfree",
"*.cl": "common-lisp","*.lisp": "common-lisp",
"*.d": "d","*.di": "d",
"*.pas": "delphi","*.dpr": "delphi",
"*.e": "eiffel",
"*.ex": "elixir","*.eex": "elixir","*.exs": "elixir","*.leex": "elixir",
"None": "iex",
"*.elm": "elm",
"*.el": "emacs-lisp",
"*.erl": "erlang","*.hrl": "erlang","*.es": "erlang","*.escript": "erlang",
"*.erl-sh": "erl",
"*.fs": "fsharp","*.fsi": "fsharp","*.fsx": "fsharp",
"*.factor": "factor",
"*.fish": "fish","*.load": "fish",
"*.frt": "forth","*.fs": "forth",
"*.f03": "fortran","*.f90": "fortran","*.F03": "fortran","*.F90": "fortran",
"*.f": "fortranfixed","*.F": "fortranfixed",
"*.go": "go",
"*.hs": "haskell",
"*.inf": "inform6",
"*.i6t": "i6t",
"*.ni": "inform7","*.i7x": "inform7",
"*.ijs": "j",
"*.java": "java",
"*.jsp": "jsp",
"*.js": "javascript","*.jsm": "javascript","*.mjs": "javascript","*.cjs": "javascript",
"*.jl": "julia",
"None": "jlcon",
"*.kt": "kotlin","*.kts": "kotlin",
"*.lua": "lua","*.wlua": "lua",
"*.mak": "make","*.mk": "make","Makefile": "make","makefile": "make","Makefile.*": "make","GNUmakefile": "make",
"*.m": "matlab",
"None": "matlabsession",
"*.monkey": "monkey",
"None": "mysql",
"*.lsp": "newlisp","*.nl": "newlisp","*.kif": "newlisp",
"*.nim": "nimrod","*.nimrod": "nimrod",
"*.m": "objective-c","*.h": "objective-c",
"*.mm": "objective-c++","*.hh": "objective-c++",
"*.pl": "perl","*.pm": "perl","*.t": "perl","*.perl": "perl",
"*.pl": "perl6","*.pm": "perl6","*.nqp": "perl6","*.p6": "perl6","*.6pl": "perl6","*.p6l": "perl6","*.pl6": "perl6","*.6pm": "perl6","*.p6m": "perl6","*.pm6": "perl6","*.t": "perl6","*.raku": "perl6","*.rakumod": "perl6","*.rakutest": "perl6","*.rakudoc": "perl6",
"*.php": "php","*.php[345]": "php","*.inc": "php",
"None": "plpgsql",
"None": "psql",
"*.explain": "postgres-explain",
"None": "postgresql",
"*.ps": "postscript","*.eps": "postscript",
"*.ps1": "powershell","*.psm1": "powershell",
"None": "pwsh-session",
"*.ecl": "prolog","*.prolog": "prolog","*.pro": "prolog","*.pl": "prolog",
"*.py": "python","*.pyw": "python","*.pyi": "python","*.jy": "python","*.sage": "python","*.sc": "python","SConstruct": "python","SConscript": "python","*.bzl": "python","BUCK": "python","BUILD": "python","BUILD.bazel": "python","WORKSPACE": "python","*.tac": "python",
"None": "python2",
"*.py2tb": "py2tb",
"None": "pycon",
"*.pytb": "pytb","*.py3tb": "pytb",
"*.pyul4": "py+ul4",
"*.BAS": "qbasic","*.bas": "qbasic",
"*.rl": "ragel-ruby",
"*.r": "rebol","*.r3": "rebol","*.reb": "rebol",
"*.red": "red","*.reds": "red",
"*.rb": "ruby","*.rbw": "ruby","Rakefile": "ruby","*.rake": "ruby","*.gemspec": "ruby","*.rbx": "ruby","*.duby": "ruby","Gemfile": "ruby","Vagrantfile": "ruby",
"None": "rbcon",
"*.rs": "rust","*.rs.in": "rust",
"*.sass": "sass",
"*.scala": "scala",
"*.scm": "scheme","*.ss": "scheme",
"*.sql": "sql",
"*.sql": "sql+jinja","*.sql.j2": "sql+jinja","*.sql.jinja2": "sql+jinja",
"*.sqlite3-console": "sqlite3",
"*.swift": "swift",
"*.tex": "tex","*.aux": "tex","*.toc": "tex",
"*.sql": "tsql",
"*.vbs": "vbscript","*.VBS": "vbscript",
"*.vhdl": "vhdl","*.vhd": "vhdl",
"*.wat": "wast","*.wast": "wast",
"*.yaml": "yaml","*.yml": "yaml",
"*.sls": "yaml+jinja","*.yaml.j2": "yaml+jinja","*.yml.j2": "yaml+jinja","*.yaml.jinja2": "yaml+jinja","*.yml.jinja2": "yaml+jinja",
"*.zig": "zig",
}
detect language from file extension, at least for some common ones