Class: Phase::IPA::App

Inherits:
Object
  • Object
show all
Defined in:
lib/phase/kit/ipa/app.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(qualified_path, version) ⇒ App

Returns a new instance of App.



7
8
9
10
# File 'lib/phase/kit/ipa/app.rb', line 7

def initialize(qualified_path, version)
  @qualified_path, @version = qualified_path, version
  @name = ::File.basename(qualified_path, ".ipa")
end

Instance Attribute Details

#download_urlObject

Returns the value of attribute download_url.



5
6
7
# File 'lib/phase/kit/ipa/app.rb', line 5

def download_url
  @download_url
end

#nameObject (readonly)

Returns the value of attribute name.



4
5
6
# File 'lib/phase/kit/ipa/app.rb', line 4

def name
  @name
end

#qualified_pathObject (readonly)

Returns the value of attribute qualified_path.



4
5
6
# File 'lib/phase/kit/ipa/app.rb', line 4

def qualified_path
  @qualified_path
end

#versionObject (readonly)

Returns the value of attribute version.



4
5
6
# File 'lib/phase/kit/ipa/app.rb', line 4

def version
  @version
end

Instance Method Details

#ipa_filenameObject



12
13
14
# File 'lib/phase/kit/ipa/app.rb', line 12

def ipa_filename
  "#{bundle_name}-#{version}.ipa"
end

#plist_filenameObject



16
17
18
# File 'lib/phase/kit/ipa/app.rb', line 16

def plist_filename
  "#{bundle_name}-#{version}.plist"
end

#plist_xmlObject



20
21
22
23
# File 'lib/phase/kit/ipa/app.rb', line 20

def plist_xml
  xml = ::File.read( ::File.expand_path("../../templates/ipa_xml.plist", __dir__) )
  ::ERB.new(xml).result(binding)
end