Class: Fastlane::Actions::CodePushReleaseReactAction
- Inherits:
-
Action
- Object
- Action
- Fastlane::Actions::CodePushReleaseReactAction
- Defined in:
- lib/fastlane/plugin/code_push/actions/code_push_release_react_action.rb
Class Method Summary collapse
- .authors ⇒ Object
- .available_options ⇒ Object
- .description ⇒ Object
- .details ⇒ Object
- .is_supported?(platform) ⇒ Boolean
- .return_value ⇒ Object
- .run(params) ⇒ Object
Class Method Details
.authors ⇒ Object
29 30 31 |
# File 'lib/fastlane/plugin/code_push/actions/code_push_release_react_action.rb', line 29 def self. ["Manuel Koch"] end |
.available_options ⇒ Object
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 |
# File 'lib/fastlane/plugin/code_push/actions/code_push_release_react_action.rb', line 42 def self. [ FastlaneCore::ConfigItem.new(key: :app_name, env_name: "FASTLANE_CODE_PUSH_APP_NAME", type: String, optional: false, description: "CodePush app name for releasing"), FastlaneCore::ConfigItem.new(key: :execution_dir_path, type: String, optional: true, default_value: "./", description: "Release React CLI command execution dir"), FastlaneCore::ConfigItem.new(key: :platform, type: String, optional: true, default_value: "android", description: "Platform for releasing to"), FastlaneCore::ConfigItem.new(key: :deployment, type: String, optional: true, default_value: "Staging", description: "Deployment name for releasing to"), FastlaneCore::ConfigItem.new(key: :target_binary_version, is_string: false, optional: true, description: "Target binary version for example 1.0.1"), FastlaneCore::ConfigItem.new(key: :mandatory, is_string: false, default_value: true, optional: true, description: "mandatory update or not"), FastlaneCore::ConfigItem.new(key: :description, type: String, optional: true, default_value: "no description for release", description: "Release description for CodePush"), FastlaneCore::ConfigItem.new(key: :dry_run, description: "Print the command that would be run, and don't run it", is_string: false, default_value: false), FastlaneCore::ConfigItem.new(key: :disabled, is_string: false, default_value: false, optional: true, description: "Specifies whether this release should be immediately downloadable") ] end |
.description ⇒ Object
25 26 27 |
# File 'lib/fastlane/plugin/code_push/actions/code_push_release_react_action.rb', line 25 def self.description "CodePush release-react functionality for fastlane" end |
.details ⇒ Object
37 38 39 40 |
# File 'lib/fastlane/plugin/code_push/actions/code_push_release_react_action.rb', line 37 def self.details # Optional: "Fastlane Cli Wrapper for CodePush's release-react command" end |
.is_supported?(platform) ⇒ Boolean
90 91 92 |
# File 'lib/fastlane/plugin/code_push/actions/code_push_release_react_action.rb', line 90 def self.is_supported?(platform) true end |
.return_value ⇒ Object
33 34 35 |
# File 'lib/fastlane/plugin/code_push/actions/code_push_release_react_action.rb', line 33 def self.return_value # If your method provides a return value, you can describe here what it does end |
.run(params) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/fastlane/plugin/code_push/actions/code_push_release_react_action.rb', line 4 def self.run(params) Dir.chdir "#{params[:execution_dir_path]}" do command = "code-push release-react #{params[:app_name]} #{params[:platform]} -d #{params[:deployment]} "\ "--des \"#{params[:description]}\" " if params[:mandatory] command += "-m " end if params[:target_binary_version] command += "-t #{params[:target_binary_version]} " end if params[:disabled] command += "-x " end if params[:dry_run] UI.("Dry run!".red + " Would have run: " + command + "\n") else sh(command.to_s) end end end |