Class: Rusic::Deployer
- Inherits:
-
Object
- Object
- Rusic::Deployer
- Defined in:
- lib/rusic/deployer.rb
Instance Attribute Summary collapse
-
#files ⇒ Object
readonly
Returns the value of attribute files.
Instance Method Summary collapse
-
#initialize(files) ⇒ Deployer
constructor
A new instance of Deployer.
- #upload_files(options = {}) ⇒ Object
Constructor Details
Instance Attribute Details
#files ⇒ Object (readonly)
Returns the value of attribute files.
3 4 5 |
# File 'lib/rusic/deployer.rb', line 3 def files @files end |
Instance Method Details
#upload_files(options = {}) ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/rusic/deployer.rb', line 9 def upload_files( = {}) files.each do |file| file.uploader.upload_file() end rescue RestClient::Unauthorized puts puts '401 Unauthorized. Ensure your API Key is set correctly.' exit(1) rescue RestClient::ResourceNotFound puts puts '404 Not Found. Ensure you are have permission to access the given theme' exit(1) end |