Class: TexturePacker::Cli
- Inherits:
-
Object
- Object
- TexturePacker::Cli
- Defined in:
- lib/texture_packer/cli.rb
Defined Under Namespace
Classes: Options
Instance Method Summary collapse
-
#initialize(argv) ⇒ Cli
constructor
A new instance of Cli.
- #run ⇒ Object
Constructor Details
Instance Method Details
#run ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/texture_packer/cli.rb', line 10 def run return @options.hook_run.call if @options.hook_run pack_css! packer = create_packer output0, output1, output2 = packer.parse! output = output0 + output1 + output2 compress_images! # 壓縮圖片 write_to_file('packed.scss', output) write_to_project_dir!(packer, output1, output2) if @options.project_dir end |