def find_misc_path(name)
      [name, name.upcase, name.downcase].each do |base|
        ['.md', '', '.txt', '.html'].each do |suffix|
          path = File.join(spec.full_gem_path, base+suffix)
          return path if File.exist?(path) && Dir.entries(File.dirname(path)).include?(File.basename(path))
        end
      end
      # Didn't find anything
      nil
    end
def find_misc_path(name)
      [name, name.upcase, name.downcase].each do |base|
        ['.md', '', '.txt', '.html'].each do |suffix|
          path = File.join(spec.full_gem_path, base+suffix)
          return path if File.exist?(path) && Dir.entries(File.dirname(path)).include?(File.basename(path))
        end
      end
      # Didn't find anything
      nil
    end
Search for a file like README.md or LICENSE.txt in the gem.

 @param name [String] Basename to search for.
 @return [String, Array<String>]
 @example
   gem.misc_file('Readme') => /path/to/readme.txt