Class: S3AssetsDeployer::Deployer

Inherits:
Object
  • Object
show all
Defined in:
lib/s3_assets_deployer/deployer.rb

Instance Method Summary collapse

Constructor Details

#initialize(storage:, root_path:, prefix_paths:, ignore_paths:) ⇒ Deployer

Returns a new instance of Deployer.



5
6
7
8
9
10
# File 'lib/s3_assets_deployer/deployer.rb', line 5

def initialize(storage:, root_path:, prefix_paths:, ignore_paths:)
  @storage = storage
  @root_path = root_path
  @prefix_paths = prefix_paths
  @ignore_paths = ignore_paths.map { |path| File.join(root_path, path) }
end

Instance Method Details

#runObject



12
13
14
# File 'lib/s3_assets_deployer/deployer.rb', line 12

def run
  @storage.upload(files)
end