Method: Fastlane::Actions::ReactPodAction.run

Defined in:
lib/fastlane/plugin/react_native_util/actions/react_pod_action.rb

.run(params) ⇒ Object



8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/fastlane/plugin/react_native_util/actions/react_pod_action.rb', line 8

def self.run(params)
  UI.message "Running in #{params[:chdir]}"
  Dir.chdir params[:chdir] do
    converter = ::ReactNativeUtil::Converter.new repo_update: params[:repo_update]

    begin
      if params[:update]
        converter.update_project!
      else
        converter.convert_to_react_pod!
      end
    rescue ::ReactNativeUtil::BaseException => e
      UI.user_error! e.message
    end
  end
end