Sha256: 3380b0bfd9cdeedd51bf29b489f47e9ee2bdefba8fdaae7227b82e045a77ea96

Contents?: true

Size: 803 Bytes

Versions: 36

Compression:

Stored size: 803 Bytes

Contents

require_relative "locations"

module Fontist
  module Manifest
    class Install < Locations
      def initialize(manifest, confirmation: "no", hide_licenses: false, no_progress: false)
        super(manifest)
        @confirmation = confirmation
        @hide_licenses = hide_licenses
        @no_progress = no_progress
      end

      private

      def file_paths(font, style)
        paths = find_font_with_name(font, style)
        return paths unless paths.nil?

        install_font(font)

        find_font_with_name(font, style)
      end

      def install_font(font)
        Fontist::Font.install(
          font,
          force: true,
          confirmation: @confirmation,
          hide_licenses: @hide_licenses,
          no_progress: @no_progress
        )
      end
    end
  end
end

Version data entries

36 entries across 36 versions & 1 rubygems

Version Path
fontist-1.21.2 lib/fontist/manifest/install.rb
fontist-1.21.1 lib/fontist/manifest/install.rb
fontist-1.20.0 lib/fontist/manifest/install.rb
fontist-1.19.0 lib/fontist/manifest/install.rb
fontist-1.18.2 lib/fontist/manifest/install.rb
fontist-1.17.1 lib/fontist/manifest/install.rb
fontist-1.17.0 lib/fontist/manifest/install.rb
fontist-1.16.0 lib/fontist/manifest/install.rb
fontist-1.15.2 lib/fontist/manifest/install.rb
fontist-1.15.1 lib/fontist/manifest/install.rb
fontist-1.15.0 lib/fontist/manifest/install.rb
fontist-1.14.6 lib/fontist/manifest/install.rb
fontist-1.14.5 lib/fontist/manifest/install.rb
fontist-1.14.4 lib/fontist/manifest/install.rb
fontist-1.14.3 lib/fontist/manifest/install.rb
fontist-1.14.2 lib/fontist/manifest/install.rb
fontist-1.14.1 lib/fontist/manifest/install.rb
fontist-1.14.0 lib/fontist/manifest/install.rb
fontist-1.13.2 lib/fontist/manifest/install.rb
fontist-1.13.1 lib/fontist/manifest/install.rb