Sha256: 24a6f7842d00b8f3a44eccc0f4c597ed69053a9c368985c3276de5ab05a726c5
Contents?: true
Size: 944 Bytes
Versions: 1
Compression:
Stored size: 944 Bytes
Contents
require 'cocoapods' module QCloudHive class HiveSpec attr_accessor :name attr_accessor :path attr_accessor :branch attr_accessor :commit attr_accessor :sourceURL def initialize(name=nil, path=nil) @name = name @path = path @podspec = nil end def podspec if @podspec.nil? @podspec = Pod::Specification.from_file(path) end return @podspec end def toConfig config = "[#{name}]\n" if not path.nil? config += "path=#{path}\n" end if not commit.nil? config += "commit=#{commit}\n" end if not branch.nil? config += "branch=#{branch}\n" end if not sourceURL.nil? config += "sourceURL=#{sourceURL}\n" end config end def writeJson jsonPath = @path + ".json" File.open("#{jsonPath}", "w") { |f| f.write podspec.to_json } end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
qcloudhive-0.1.0 | lib/qcloudhive/spec_helper.rb |