Class: Rouge::Lexers::Crystal

Inherits:
RegexLexer
  • Object
show all
Defined in:
lib/rouge/lexers/crystal.rb

Class Method Summary collapse

Class Method Details

.analyze_text(text) ⇒ Object



23
24
25
# File 'lib/rouge/lexers/crystal.rb', line 23

def self.analyze_text(text)
  return 1 if text.shebang? 'crystal'
end

.detect?(text) ⇒ Boolean

Returns:

  • (Boolean)


19
20
21
# File 'lib/rouge/lexers/crystal.rb', line 19

def self.detect?(text)
  return true if text.shebang? 'crystal'
end