mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 17:50:22 +00:00
Fix groovy regexp warning
This commit is contained in:
@@ -434,19 +434,17 @@ module Linguist
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
# Internal: Guess language of .gsp files.
|
||||
#
|
||||
# Returns a Language.
|
||||
def guess_gsp_language
|
||||
if lines.grep(/<%|<%@|\${|<%|<g:|<meta name="layout"|<r:/).any?
|
||||
if lines.grep(/<%|<%@|\$\{|<%|<g:|<meta name="layout"|<r:/).any?
|
||||
Language['Groovy Server Pages']
|
||||
else
|
||||
Language['Gosu']
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
# Internal: Guess language from the first line.
|
||||
#
|
||||
# Look for leading "<?php"
|
||||
|
||||
Reference in New Issue
Block a user