Skip to content
Snippets Groups Projects
Commit ce33f593 authored by Josh Hagins's avatar Josh Hagins Committed by Josh Hagins
Browse files

metafiles: convert EXTENSIONS and BASENAMES from Array to Set

parent c46155ab
No related branches found
No related tags found
No related merge requests found
require "set"
class Metafiles class Metafiles
# https://github.com/github/markup#markups # https://github.com/github/markup#markups
EXTENSIONS = %w[ EXTENSIONS = %w[
.adoc .asc .asciidoc .creole .html .markdown .md .mdown .mediawiki .mkdn .adoc .asc .asciidoc .creole .html .markdown .md .mdown .mediawiki .mkdn
.org .pod .rdoc .rst .rtf .textile .txt .wiki .org .pod .rdoc .rst .rtf .textile .txt .wiki
].freeze ].to_set.freeze
BASENAMES = %w[ BASENAMES = %w[
about authors changelog changes copying copyright history license licence about authors changelog changes copying copyright history license licence
news notes notice readme todo news notes notice readme todo
].freeze ].to_set.freeze
def self.list?(file) def self.list?(file)
return false if %w[.DS_Store INSTALL_RECEIPT.json].include?(file) return false if %w[.DS_Store INSTALL_RECEIPT.json].include?(file)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment