Class: Fontist::FontInstaller
- Inherits:
-
Object
- Object
- Fontist::FontInstaller
- Defined in:
- lib/fontist/font_installer.rb
Instance Method Summary collapse
-
#initialize(formula, no_progress: false) ⇒ FontInstaller
constructor
A new instance of FontInstaller.
- #install(confirmation:) ⇒ Object
Constructor Details
#initialize(formula, no_progress: false) ⇒ FontInstaller
Returns a new instance of FontInstaller.
6 7 8 9 |
# File 'lib/fontist/font_installer.rb', line 6 def initialize(formula, no_progress: false) @formula = formula @no_progress = no_progress end |
Instance Method Details
#install(confirmation:) ⇒ Object
11 12 13 14 15 16 17 |
# File 'lib/fontist/font_installer.rb', line 11 def install(confirmation:) if @formula.license_required && !"yes".casecmp?(confirmation) raise(Fontist::Errors::LicensingError) end install_font end |