Sha256: 0d8652d396846c6a28228fdf8f0ba6e2e9b12e14cde05022aaa9ef6638906cb8

Contents?: true

Size: 601 Bytes

Versions: 8

Compression:

Stored size: 601 Bytes

Contents

require_relative "google/new_fonts_fetcher"

module Fontist
  module Import
    class GoogleCheck
      def call
        fetch_formulas
        fonts = new_fonts
        indicate(fonts)
      end

      private

      def fetch_formulas
        Formulas.fetch_formulas
      end

      def new_fonts
        Fontist::Import::Google::NewFontsFetcher.new(logging: true).call
      end

      def indicate(new_paths)
        return if new_paths.empty?

        puts "New fonts are available in:"
        new_paths.each do |path|
          puts path
        end

        abort
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
fontist-1.7.3 lib/fontist/import/google_check.rb
fontist-1.7.2 lib/fontist/import/google_check.rb
fontist-1.7.1 lib/fontist/import/google_check.rb
fontist-1.7.0 lib/fontist/import/google_check.rb
fontist-1.6.0 lib/fontist/import/google_check.rb
fontist-1.5.1 lib/fontist/import/google_check.rb
fontist-1.5.0 lib/fontist/import/google_check.rb
fontist-1.4.0 lib/fontist/import/google_check.rb