EntryFilter#special? should also check the base name of the entry
This commit is contained in:
parent
f0e68d7d86
commit
323ea0ef73
|
@ -1,5 +1,7 @@
|
||||||
module Jekyll
|
module Jekyll
|
||||||
class EntryFilter
|
class EntryFilter
|
||||||
|
SPECIAL_LEADING_CHARACTERS = ['.', '_', '#'].freeze
|
||||||
|
|
||||||
attr_reader :site
|
attr_reader :site
|
||||||
|
|
||||||
def initialize(site, base_directory = nil)
|
def initialize(site, base_directory = nil)
|
||||||
|
@ -35,7 +37,8 @@ module Jekyll
|
||||||
end
|
end
|
||||||
|
|
||||||
def special?(entry)
|
def special?(entry)
|
||||||
['.', '_', '#'].include?(entry[0..0])
|
SPECIAL_LEADING_CHARACTERS.include?(entry[0..0]) ||
|
||||||
|
SPECIAL_LEADING_CHARACTERS.include?(File.basename(entry)[0..0])
|
||||||
end
|
end
|
||||||
|
|
||||||
def backup?(entry)
|
def backup?(entry)
|
||||||
|
|
Loading…
Reference in New Issue