Skip to content

Bash syntax highlighter renders $# incorrectly as the beginning of a comment #200

@maidentaiwan

Description

@maidentaiwan

Describe the bug
Bash syntax highlighter treats $# as the beginning of a comment instead of a variable.

WordPress Editing Mode
Classic editor, but it doesn't matter because it's a rendering bug

Frontend or Backend Issue
Frontend

To Reproduce
See screenshot line 4 for incorrect highlighting.
Use Block-Code, Bash script, Standard (enlighter) settings

Expected behavior
The syntax $# should be highlighted like a variable, not like a comment.

Screenshots
Screenshot_20221017_121301

Example code
If applicable, add a small code snippet which causes the issue.

if [ $# -ne 2]; then

Desktop (please complete the following information):

  • OS: Ubuntu Linux 18.04 LTS
  • Browser Chrome
  • Version 106.0.5249.119 (Official Build) (64-bit)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions