fastlane-old / snapshot

Automate taking localized screenshots of your iOS app on every device
https://fastlane.tools
1.95k stars 140 forks source link

unable to use snapshot --devices command line parameter #341

Closed jochen-st closed 8 years ago

jochen-st commented 9 years ago

I want to override the devices list in Snapfile. However all I am getting is Devices must be an array error message.

Tried with

but no success. Running latest snapshot gem with Mac OS Yosemite.

Error message:

[15:34:23]: Error setting value 'true' for option 'devices'
/Library/Ruby/Gems/2.0.0/gems/snapshot-1.4.0/lib/snapshot/options.rb:37:in `block in available_options': Devices must be an array (RuntimeError)
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/config_item.rb:53:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/config_item.rb:53:in `valid?'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/config_item.rb:38:in `verify!'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/configuration.rb:59:in `block in verify_value_exists'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/configuration.rb:54:in `each'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/configuration.rb:54:in `verify_value_exists'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/configuration.rb:39:in `initialize'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/configuration.rb:27:in `new'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.27.0/lib/fastlane_core/configuration/configuration.rb:27:in `create'
    from /Library/Ruby/Gems/2.0.0/gems/snapshot-1.4.0/bin/snapshot:34:in `block (2 levels) in run'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:178:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:178:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:153:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/runner.rb:428:in `run_active_command'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/runner.rb:68:in `run!'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/delegates.rb:15:in `run!'
    from /Library/Ruby/Gems/2.0.0/gems/snapshot-1.4.0/bin/snapshot:78:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/snapshot-1.4.0/bin/snapshot:84:in `<top (required)>'
    from /usr/bin/snapshot:23:in `load'
    from /usr/bin/snapshot:23:in `<main>'

Kindly update documentation with usage hint.

kkestell commented 9 years ago

snapshot --languages crashes too with a undefined method 'each' for true:TrueClass (NoMethodError) in runner.rb:28

jochen-st commented 8 years ago

The language issue is basically the same problem. The error is different since the type of the language argument is not checked to be Array, but the array method .each is called on a string object.

jochen-st commented 8 years ago

see also #354 which uses fastlane/fastlane_core#52

fastlanebot commented 8 years ago

This issue was migrated to https://github.com/fastlane/fastlane/issues/2530. Please post all further comments there.

fastlane is now a mono repo, you can read more about the change in our blog post. All tools are now available in the fastlane main repo :rocket: