Class: Embarista::GenerateS3IndexTask

Inherits:
Rake::TaskLib
  • Object
show all
Defined in:
lib/embarista/tasks/generate_s3_index.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name = :generate_s3_index) {|_self| ... } ⇒ GenerateS3IndexTask

Returns a new instance of GenerateS3IndexTask.

Yields:

  • (_self)

Yield Parameters:



8
9
10
11
12
13
14
15
16
17
18
# File 'lib/embarista/tasks/generate_s3_index.rb', line 8

def initialize(name = :generate_s3_index)
  @name = name
  @erb_path = "app/index.html.erb"

  yield self if block_given?

  @assets_bucket ||= App.assets_bucket

  raise 'app must be set' unless @app
  define
end

Instance Attribute Details

#appObject

Returns the value of attribute app.



6
7
8
# File 'lib/embarista/tasks/generate_s3_index.rb', line 6

def app
  @app
end

#assets_bucketObject

Returns the value of attribute assets_bucket.



6
7
8
# File 'lib/embarista/tasks/generate_s3_index.rb', line 6

def assets_bucket
  @assets_bucket
end

#erb_pathObject

Returns the value of attribute erb_path.



6
7
8
# File 'lib/embarista/tasks/generate_s3_index.rb', line 6

def erb_path
  @erb_path
end

#nameObject

Returns the value of attribute name.



6
7
8
# File 'lib/embarista/tasks/generate_s3_index.rb', line 6

def name
  @name
end