Skip to content

Files

Latest commit

 

History

History
39 lines (28 loc) · 750 Bytes

Naming-HeredocDelimiterNaming.md

File metadata and controls

39 lines (28 loc) · 750 Bytes

Pattern: Invalid heredoc delimiter name

Issue: -

Description

This rule checks that your heredocs are using meaningful delimiters. By default it disallows END and EO*, and can be configured through blacklisting additional delimiters.

Examples

# good
<<-SQL
  SELECT * FROM foo
SQL

# bad
<<-END
  SELECT * FROM foo
END

# bad
<<-EOS
  SELECT * FROM foo
EOS

Default configuration

Attribute Value
Blacklist END, (?-mix:EO[A-Z]{1})

Further Reading