Class: Highway::Steps::Library::AppStoreStep

Inherits:
Step
  • Object
show all
Defined in:
lib/highway/steps/library/appstore.rb

Class Method Summary collapse

Methods inherited from Step

root_parameter

Class Method Details

.nameObject



16
17
18
# File 'lib/highway/steps/library/appstore.rb', line 16

def self.name
  "appstore"
end

.parametersObject



20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
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
89
90
91
92
# File 'lib/highway/steps/library/appstore.rb', line 20

def self.parameters
  [
    Parameters::Single.new(
      name: "app_identifier",
      required: true,
      type: Types::String.new()
    ),
    Parameters::Single.new(
      name: "build_number",
      required: false,
      type: Types::String.new()
    ),
    Parameters::Single.new(
      name: "force",
      required: false,
      default: true,
      type: Types::Bool.new()
    ),
    Parameters::Single.new(
      name: "metadata_path",
      required: false,
      type: Types::String.new()
    ),
    Parameters::Single.new(
      name: "password",
      required: true,
      type: Types::String.new()
    ),
    Parameters::Single.new(
      name: "session",
      required: false,
      type: Types::String.new()
    ),
    Parameters::Single.new(
      name: "screenshots_path",
      required: false,
      type: Types::String.new()
    ),
    Parameters::Single.new(
      name: "skip_app_version_update",
      required: false,
      default: false,
      type: Types::Bool.new()
    ),
    Parameters::Single.new(
      name: "skip_binary_upload",
      required: false,
      default: false,
      type: Types::Bool.new()
    ),
    Parameters::Single.new(
      name: "submit_for_review",
      required: false,
      default: false,
      type: Types::Bool.new()
    ),
    Parameters::Single.new(
      name: "team_id",
      required: false,
      type: Types::String.new()
    ),
    Parameters::Single.new(
      name: "team_name",
      required: false,
      type: Types::String.new()
    ),
    Parameters::Single.new(
      name: "username",
      required: true,
      type: Types::String.regex(/^\S+@\S+\.\S+$/)
    )
  ]
end

.run(parameters:, context:, report:) ⇒ Object



94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
# File 'lib/highway/steps/library/appstore.rb', line 94

def self.run(parameters:, context:, report:)

  username = parameters["username"]
  password = parameters["password"]
  session = parameters["session"]
  app_identifier = parameters["app_identifier"]
   = parameters["metadata_path"]
  screenshots_path = parameters["screenshots_path"]
  skip_app_version_update = parameters["skip_app_version_update"]
  submit_for_review = parameters["submit_for_review"]
  team_id = parameters["team_id"]
  team_name = parameters["team_name"]
  skip_binary_upload = parameters["skip_binary_upload"]
  force = parameters["force"]
  build_number = parameters["build_number"]

  env = {
    "FASTLANE_PASSWORD" => password,
    "FASTLANE_SESSION" => session
  }

  context.with_modified_env(env) {
    context.run_action("upload_to_app_store", options: {
      username: username,
      app_identifier: app_identifier,
      metadata_path: ,
      screenshots_path: screenshots_path,
      skip_app_version_update: skip_app_version_update,
      submit_for_review: submit_for_review,
      team_id: team_id,
      skip_binary_upload: skip_binary_upload,
      build_number: build_number,
      team_name: team_name,
      force: force
    })
  }
  
end