Class: Pod::Command::ChangeColor

Inherits:
Pod::Command show all
Defined in:
lib/cocoapods-hooks/command/change_color.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(argv) ⇒ ChangeColor

Returns a new instance of ChangeColor.



8
9
10
# File 'lib/cocoapods-hooks/command/change_color.rb', line 8

def initialize(argv)
  super
end

Class Method Details

.changeThemeColorObject



30
31
32
33
34
35
# File 'lib/cocoapods-hooks/command/change_color.rb', line 30

def self.changeThemeColor()
  # 改变 theme 文件夹的图片颜色
  system("python3 ChangeColor.py")
  # 改变 mutableTheme 文件夹的图片颜色
  system("python3 svg2png.py")
end

.optionsObject



12
13
14
15
16
# File 'lib/cocoapods-hooks/command/change_color.rb', line 12

def self.options
  [

  ].concat(super)
end

Instance Method Details

#runObject



22
23
24
25
26
# File 'lib/cocoapods-hooks/command/change_color.rb', line 22

def run
  UI.puts "change project theme color for theme and mutable theme #{@tenantid}"
  # 执行你的业务逻辑
  self.class.changeThemeColor()
end

#validate!Object



18
19
20
# File 'lib/cocoapods-hooks/command/change_color.rb', line 18

def validate!
  super
end