Class: S3SignedUrl::Cli

Inherits:
Object
  • Object
show all
Defined in:
lib/s3_signed_url/cli.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(s3_url, options = {}) ⇒ Cli

Returns a new instance of Cli.



8
9
10
11
# File 'lib/s3_signed_url/cli.rb', line 8

def initialize(s3_url, options = {})
  @s3_uri = URI(s3_url)
  @options = options
end

Instance Attribute Details

#optionsObject (readonly)

Returns the value of attribute options.



6
7
8
# File 'lib/s3_signed_url/cli.rb', line 6

def options
  @options
end

#s3_uriObject (readonly)

Returns the value of attribute s3_uri.



6
7
8
# File 'lib/s3_signed_url/cli.rb', line 6

def s3_uri
  @s3_uri
end

Instance Method Details

#runObject



13
14
15
16
# File 'lib/s3_signed_url/cli.rb', line 13

def run
  upload
  generate_presigned_url
end