Class: Geb::CLI::Commands::Upload

Inherits:
Dry::CLI::Command
  • Object
show all
Defined in:
lib/geb/commands/upload.rb

Overview

Define upload command

Instance Method Summary collapse

Instance Method Details

#callObject

Call method for the remote command



27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# File 'lib/geb/commands/upload.rb', line 27

def call(*)

  # initialise a new site and load the site from the current directory
  site = Geb::Site.new
  site.load(Dir.pwd)

  # check if the site has been released before uploading
  site.upload_release_to_remote()

rescue Geb::Error => e

  # print error message
  puts
  warn e.message

end