summaryrefslogtreecommitdiff
path: root/lib/chef/resource/archive_file.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chef/resource/archive_file.rb')
-rw-r--r--lib/chef/resource/archive_file.rb26
1 files changed, 13 insertions, 13 deletions
diff --git a/lib/chef/resource/archive_file.rb b/lib/chef/resource/archive_file.rb
index 18a6a2d5a0..958da23a1b 100644
--- a/lib/chef/resource/archive_file.rb
+++ b/lib/chef/resource/archive_file.rb
@@ -32,31 +32,31 @@ class Chef
description "Use the archive_file resource to extract archive files to disk. This resource uses the libarchive library to extract multiple archive formats including tar, gzip, bzip, and zip formats."
property :path, String,
- name_property: true,
- coerce: proc { |f| ::File.expand_path(f) },
- description: "An optional property to set the file path to the archive to extract if it differs from the resource block's name."
+ name_property: true,
+ coerce: proc { |f| ::File.expand_path(f) },
+ description: "An optional property to set the file path to the archive to extract if it differs from the resource block's name."
property :owner, String,
- description: "The owner of the extracted files."
+ description: "The owner of the extracted files."
property :group, String,
- description: "The group of the extracted files."
+ description: "The group of the extracted files."
property :mode, [String, Integer],
- description: "The mode of the extracted files.",
- default: "755"
+ description: "The mode of the extracted files.",
+ default: "755"
property :destination, String,
- description: "The file path to extract the archive file to.",
- required: true
+ description: "The file path to extract the archive file to.",
+ required: true
property :options, [Array, Symbol],
- description: "An array of symbols representing extraction flags. Example: :no_overwrite to prevent overwriting files on disk. By default, this properly sets :time which preserves the modification timestamps of files in the archive when writing them to disk.",
- default: lazy { [:time] }
+ description: "An array of symbols representing extraction flags. Example: :no_overwrite to prevent overwriting files on disk. By default, this properly sets :time which preserves the modification timestamps of files in the archive when writing them to disk.",
+ default: lazy { [:time] }
property :overwrite, [TrueClass, FalseClass, :auto],
- description: "Should the resource overwrite the destination file contents if they already exist? If set to :auto the date stamp of files within the archive will be compared to those on disk and disk contents will be overwritten if they differ. This may cause unintended consequences if disk date stamps are changed between runs, which will result in the files being overwritten during each client run. Make sure to properly test any change to this property.",
- default: false
+ description: "Should the resource overwrite the destination file contents if they already exist? If set to :auto the date stamp of files within the archive will be compared to those on disk and disk contents will be overwritten if they differ. This may cause unintended consequences if disk date stamps are changed between runs, which will result in the files being overwritten during each client run. Make sure to properly test any change to this property.",
+ default: false
# backwards compatibility for the legacy cookbook names
alias_method :extract_options, :options