module DeployGate::Commands::Deploy

Public Class Methods

run(args, options) click to toggle source

@param [Array] args @param [Commander::Command::Options] options

# File lib/deploygate/commands/deploy.rb, line 8
def run(args, options)
  Login.start_login_or_create_account() unless DeployGate::Session.new.login?

  # push or build(android/ios)
  args.push(Dir.pwd) if args.empty?

  work_file_path = args.first
  if File.directory?(work_file_path)
    Build.run(args, options)
  else
    # file upload
    Push.upload(args, options)
  end
end