Skip to content

languages: Highlight bash conditionals and arithmetic operators#56484

Merged
ChristopherBiscardi merged 1 commit into
zed-industries:mainfrom
terror:highlight-bash-conditionals
May 14, 2026
Merged

languages: Highlight bash conditionals and arithmetic operators#56484
ChristopherBiscardi merged 1 commit into
zed-industries:mainfrom
terror:highlight-bash-conditionals

Conversation

@terror

@terror terror commented May 12, 2026

Copy link
Copy Markdown
Contributor

Resolves #56478

This diff fixes Bash syntax highlighting for conditional and arithmetic expressions. The Bash parser already recognizes tokens like [[, ]], ((, )), $((, !=, and ||, but Zed’s Bash highlight query was not capturing several of them.

With this change, the Bash highlight query styles those operators and delimiters consistently with existing shell operators, brackets, and special punctuation.

Before After
ayu-old ayu-new

Release Notes:

  • Fixed bash syntax highlighting for conditional expressions, arithmetic expressions, and related operators.

@cla-bot cla-bot Bot added the cla-signed The user has signed the Contributor License Agreement label May 12, 2026
@ChristopherBiscardi ChristopherBiscardi added the area:languages/bash Bash scripting support label May 12, 2026
@osiewicz

Copy link
Copy Markdown
Member

Thank you!

@ChristopherBiscardi ChristopherBiscardi added this pull request to the merge queue May 14, 2026
Merged via the queue into zed-industries:main with commit 5e36ec8 May 14, 2026
43 checks passed
@terror terror changed the title Highlight bash conditionals and arithmetic operators languages: Highlight bash conditionals and arithmetic operators May 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:languages/bash Bash scripting support cla-signed The user has signed the Contributor License Agreement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bash conditionals and operators not properly highlighted

3 participants