Skip to content

Commit

Permalink
bash/tcsh: move "break" to keywords (#2377)
Browse files Browse the repository at this point in the history
Fixes #2374
  • Loading branch information
birkenfeld committed Mar 15, 2023
1 parent 11ef5aa commit 15f222a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
8 changes: 4 additions & 4 deletions pygments/lexers/shell.py
Expand Up @@ -55,9 +55,9 @@ class BashLexer(RegexLexer):
],
'basic': [
(r'\b(if|fi|else|while|in|do|done|for|then|return|function|case|'
r'select|continue|until|esac|elif)(\s*)\b',
r'select|break|continue|until|esac|elif)(\s*)\b',
bygroups(Keyword, Whitespace)),
(r'\b(alias|bg|bind|break|builtin|caller|cd|command|compgen|'
(r'\b(alias|bg|bind|builtin|caller|cd|command|compgen|'
r'complete|declare|dirs|disown|echo|enable|eval|exec|exit|'
r'export|false|fc|fg|getopts|hash|help|history|jobs|kill|let|'
r'local|logout|popd|printf|pushd|pwd|read|readonly|set|shift|'
Expand Down Expand Up @@ -591,9 +591,9 @@ class TcshLexer(RegexLexer):
],
'basic': [
(r'\b(if|endif|else|while|then|foreach|case|default|'
r'continue|goto|breaksw|end|switch|endsw)\s*\b',
r'break|continue|goto|breaksw|end|switch|endsw)\s*\b',
Keyword),
(r'\b(alias|alloc|bg|bindkey|break|builtins|bye|caller|cd|chdir|'
(r'\b(alias|alloc|bg|bindkey|builtins|bye|caller|cd|chdir|'
r'complete|dirs|echo|echotc|eval|exec|exit|fg|filetest|getxvers|'
r'glob|getspath|hashstat|history|hup|inlib|jobs|kill|'
r'limit|log|login|logout|ls-F|migrate|newgrp|nice|nohup|notify|'
Expand Down
12 changes: 6 additions & 6 deletions tests/examplefiles/bash/ltmain.sh.output

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 15f222a

Please sign in to comment.