diff options
author | Kaleb Elwert <belak@coded.io> | 2016-08-18 16:21:09 -0700 |
---|---|---|
committer | Kaleb Elwert <belak@coded.io> | 2016-08-18 16:21:09 -0700 |
commit | 8e05673f8986144087bc7a280308929327e88641 (patch) | |
tree | a59748ab6b4df09928ca4e3822dbc6893e5e78d6 /pygments | |
parent | 421263e90981c08119640d280af96550e9f5fd05 (diff) | |
download | pygments-8e05673f8986144087bc7a280308929327e88641.tar.gz |
Highlight zsh files using the BashLexer
Diffstat (limited to 'pygments')
-rw-r--r-- | pygments/lexers/_mapping.py | 2 | ||||
-rw-r--r-- | pygments/lexers/shell.py | 9 |
2 files changed, 6 insertions, 5 deletions
diff --git a/pygments/lexers/_mapping.py b/pygments/lexers/_mapping.py index a6097b1c..49a87c7b 100644 --- a/pygments/lexers/_mapping.py +++ b/pygments/lexers/_mapping.py @@ -51,7 +51,7 @@ LEXERS = { 'BCLexer': ('pygments.lexers.algebra', 'BC', ('bc',), ('*.bc',), ()), 'BSTLexer': ('pygments.lexers.bibtex', 'BST', ('bst', 'bst-pybtex'), ('*.bst',), ()), 'BaseMakefileLexer': ('pygments.lexers.make', 'Base Makefile', ('basemake',), (), ()), - 'BashLexer': ('pygments.lexers.shell', 'Bash', ('bash', 'sh', 'ksh', 'shell'), ('*.sh', '*.ksh', '*.bash', '*.ebuild', '*.eclass', '*.exheres-0', '*.exlib', '.bashrc', 'bashrc', '.bash_*', 'bash_*', 'PKGBUILD'), ('application/x-sh', 'application/x-shellscript')), + 'BashLexer': ('pygments.lexers.shell', 'Bash', ('bash', 'sh', 'ksh', 'zsh', 'shell'), ('*.sh', '*.ksh', '*.bash', '*.ebuild', '*.eclass', '*.exheres-0', '*.exlib', '*.zsh', '.bashrc', 'bashrc', '.bash_*', 'bash_*', 'zshrc', '.zshrc', 'PKGBUILD'), ('application/x-sh', 'application/x-shellscript')), 'BashSessionLexer': ('pygments.lexers.shell', 'Bash Session', ('console', 'shell-session'), ('*.sh-session', '*.shell-session'), ('application/x-shell-session', 'application/x-sh-session')), 'BatchLexer': ('pygments.lexers.shell', 'Batchfile', ('bat', 'batch', 'dosbatch', 'winbatch'), ('*.bat', '*.cmd'), ('application/x-dos-batch',)), 'BefungeLexer': ('pygments.lexers.esoteric', 'Befunge', ('befunge',), ('*.befunge',), ('application/x-befunge',)), diff --git a/pygments/lexers/shell.py b/pygments/lexers/shell.py index a5933afb..752e71a7 100644 --- a/pygments/lexers/shell.py +++ b/pygments/lexers/shell.py @@ -27,16 +27,17 @@ line_re = re.compile('.*?\n') class BashLexer(RegexLexer): """ - Lexer for (ba|k|)sh shell scripts. + Lexer for (ba|k|z|)sh shell scripts. .. versionadded:: 0.6 """ name = 'Bash' - aliases = ['bash', 'sh', 'ksh', 'shell'] + aliases = ['bash', 'sh', 'ksh', 'zsh', 'shell'] filenames = ['*.sh', '*.ksh', '*.bash', '*.ebuild', '*.eclass', - '*.exheres-0', '*.exlib', - '.bashrc', 'bashrc', '.bash_*', 'bash_*', 'PKGBUILD'] + '*.exheres-0', '*.exlib', '*.zsh', + '.bashrc', 'bashrc', '.bash_*', 'bash_*', 'zshrc', '.zshrc', + 'PKGBUILD'] mimetypes = ['application/x-sh', 'application/x-shellscript'] tokens = { |