Class: FlutterRb::PodspecParser

Inherits:
Object
  • Object
show all
Defined in:
lib/flutter_rb/project/specs/ios/podspec.rb

Overview

Podspec parser

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ PodspecParser

Returns a new instance of PodspecParser.



25
26
27
# File 'lib/flutter_rb/project/specs/ios/podspec.rb', line 25

def initialize(path)
  @path = path
end

Instance Method Details

#parseObject



29
30
31
32
33
34
35
36
37
38
# File 'lib/flutter_rb/project/specs/ios/podspec.rb', line 29

def parse
  podspec = Pod::Specification.from_file(@path)
  @podspec = Podspec.new(
    @path,
    podspec.name,
    podspec.version.version,
    podspec.authors.nil? ? podspec.author : podspec.authors,
    podspec.source
  )
end