Sha256: de21759f36ba1fbf6fd8b28f52c3bcb90f344304ef8f8800e07e92c1923891df
Contents?: true
Size: 739 Bytes
Versions: 14
Compression:
Stored size: 739 Bytes
Contents
# frozen_string_literal: true namespace :manifest do def gemmable_files `git ls-files -z`.split("\x0").reject do |file| file.match(%r{^(bin|spec)/}) || file.end_with?("/.keep") || file.start_with?(".") || %w(Manifest.txt Gemfile Rakefile publify_core.gemspec).include?(file) end end def manifest_files File.open("Manifest.txt").readlines.map(&:chomp) end desc "Create manifest" task :create do File.open("Manifest.txt", "w") do |manifest| gemmable_files.each { |file| manifest.puts file } end end desc "Check manifest" task :check do unless gemmable_files == manifest_files raise "Manifest check failed, try recreating the manifest" end end end
Version data entries
14 entries across 14 versions & 1 rubygems