lib/cocoapods-playgrounds/command/playgrounds.rb in cocoapods-playgrounds-1.0.0 vs lib/cocoapods-playgrounds/command/playgrounds.rb in cocoapods-playgrounds-1.1.0
- old
+ new
@@ -7,13 +7,20 @@
Generates a Swift Playground for any Pod.
DESC
self.arguments = [CLAide::Argument.new('NAMES', true)]
+ def self.options
+ [
+ ['--no-install', 'Skip running `pod install`']
+ ]
+ end
+
def initialize(argv)
arg = argv.shift_argument
@names = arg.split(',') if arg
+ @install = argv.flag?('install', true)
super
end
def validate!
super
@@ -21,10 +28,10 @@
end
def run
# TODO: Pass platform and deployment target from configuration
generator = WorkspaceGenerator.new(@names)
- generator.generate
+ generator.generate(@install)
end
end
end
end