Class: Pod::Command::Binary::Package
Constant Summary
FIRE_FLAG
Class Method Summary
collapse
Instance Method Summary
collapse
#fire_sources, #first_podspec
Constructor Details
#initialize(argv) ⇒ Package
Returns a new instance of Package.
26
27
28
29
30
31
32
33
|
# File 'lib/cocoapods-tdfire-binary/command/package.rb', line 26
def initialize(argv)
@clean = argv.flag?('clean')
@local = argv.flag?('local')
@use_carthage = argv.flag?('use-carthage')
@spec_sources = argv.option('spec-sources')
@spec_file = first_podspec
super
end
|
Class Method Details
.options ⇒ Object
17
18
19
20
21
22
23
24
|
# File 'lib/cocoapods-tdfire-binary/command/package.rb', line 17
def self.options
[
['--clean', '执行成功后,删除 zip 文件外的所有生成文件'],
['--spec-sources', '私有源地址'],
['--use-carthage', 'carthage使用carthage进行打包'],
].concat(super)
end
|
Instance Method Details
#run ⇒ Object
40
41
42
43
44
45
46
47
48
49
50
|
# File 'lib/cocoapods-tdfire-binary/command/package.rb', line 40
def run
Pod::Tdfire::BinaryStateStore.limit_platform = true
spec = Specification.from_file(@spec_file)
prepare(spec)
package(spec)
zip(spec)
Pod::Tdfire::BinaryStateStore.limit_platform = false
end
|
#validate! ⇒ Object
35
36
37
38
|
# File 'lib/cocoapods-tdfire-binary/command/package.rb', line 35
def validate!
super
help! '当前目录下没有podspec文件.' if @spec_file.nil?
end
|