Skip to content

Commit

Permalink
Fixed mismatch error between README and resource code, now using 's3_…
Browse files Browse the repository at this point in the history
…time_prefix' everywhere.
  • Loading branch information
flatrocks committed May 22, 2015
1 parent bcab906 commit 35ddba1
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ The S3 bucket to back up into.
The S3 access_key_id.
* __s3_secret_access_key__ - kind_of: String, required: true.
The S3 secret_access_key.
* __s3_date_prefix__ - kind_of: String,, default: '%d-%b-%Y'.
The prefix used with each saved object name.
This string is processed using the Ruby Time.strftime() function so this
prefix is useful to name backups by date, etc.
For example, the default might resolve to this: "20-May-2015",
* __s3_time_prefix__ - kind_of: String,, default: '%d-%b-%Y'.
The s3_time_prefix is processed using the Ruby Time.strftime() function
and prepended to each saved object name.
The usual usage is to provide a date prefix for a daily backup.
For example, on May 20th, 2015, the default will resolve to: "20-May-2015".
See Ruby Time.strftime() docs for more examples.

__Logging:__
Expand Down
2 changes: 1 addition & 1 deletion libraries/provider_s3_backup_base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def action_create
'access_key_id' => new_resource.s3_access_key_id,
'secret_access_key' => new_resource.s3_secret_access_key,
'bucket' => new_resource.s3_bucket,
'time_prefix' => new_resource.time_prefix
'time_prefix' => new_resource.s3_time_prefix
},
'log' => {
'ident' => new_resource.log_ident,
Expand Down
4 changes: 2 additions & 2 deletions libraries/resource_s3_backup_base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ def s3_access_key_id(arg = nil)
def s3_secret_access_key(arg = nil)
set_or_return :s3_secret_access_key, arg, kind_of: String, required: true
end
def time_prefix(arg = nil)
set_or_return :time_prefix, arg, kind_of: String, default: '%d-%b-%Y'
def s3_time_prefix(arg = nil)
set_or_return :s3_time_prefix, arg, kind_of: String, default: '%d-%b-%Y'
end

def log_ident(arg = nil)
Expand Down

0 comments on commit 35ddba1

Please sign in to comment.