diff options
author | Tim Smith <tsmith@chef.io> | 2020-01-30 16:47:18 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-01-30 16:47:18 -0800 |
commit | 2ccd40f3a2e84c1f6e3608f5e6e3a2d1169941b0 (patch) | |
tree | 686a5308867ba2a00bd5eb23c491485c013d901e | |
parent | 10bdda089169f74ba04ff6a977fe98e26f6b43bb (diff) | |
parent | 968eacf74be1f175c68df7ae9963ce7aa585af40 (diff) | |
download | chef-2ccd40f3a2e84c1f6e3608f5e6e3a2d1169941b0.tar.gz |
Merge pull request #9310 from chef/docs
declare_resource.rb: consistently use `/x/y.txt`
-rw-r--r-- | lib/chef/dsl/declare_resource.rb | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/chef/dsl/declare_resource.rb b/lib/chef/dsl/declare_resource.rb index 7ae1551c04..a4272a5f28 100644 --- a/lib/chef/dsl/declare_resource.rb +++ b/lib/chef/dsl/declare_resource.rb @@ -69,7 +69,7 @@ class Chef # @return [Chef::Resource] The resource # # @example - # delete_resource!(:template, '/x/y.txy') + # delete_resource!(:template, '/x/y.txt') # def delete_resource!(type, name, run_context: self.run_context) run_context.resource_collection.delete("#{type}[#{name}]").tap do |resource| @@ -93,7 +93,7 @@ class Chef # @return [Chef::Resource] The resource # # @example - # delete_resource(:template, '/x/y.txy') + # delete_resource(:template, '/x/y.txt') # def delete_resource(type, name, run_context: self.run_context) delete_resource!(type, name, run_context: run_context) @@ -114,7 +114,7 @@ class Chef # @return [Chef::Resource] The updated resource # # @example - # edit_resource!(:template, '/x/y.txy') do + # edit_resource!(:template, '/x/y.txt') do # cookbook_name: cookbook_name # end # @@ -147,8 +147,8 @@ class Chef # @return [Chef::Resource] The updated or created resource # # @example - # resource = edit_resource(:template, '/x/y.txy') do - # source "y.txy.erb" + # resource = edit_resource(:template, '/x/y.txt') do + # source "y.txt.erb" # variables {} # end # resource.variables.merge!({ home: "/home/klowns" }) @@ -199,7 +199,7 @@ class Chef # @return [Chef::Resource] The updated resource # # @example - # resource = find_resource!(:template, '/x/y.txy') + # resource = find_resource!(:template, '/x/y.txt') # def find_resource!(type, name, run_context: self.run_context) raise ArgumentError, "find_resource! does not take a block" if block_given? @@ -219,7 +219,7 @@ class Chef # @return [Chef::Resource] The updated resource # # @example - # if ( find_resource(:template, '/x/y.txy') ) + # if ( find_resource(:template, '/x/y.txt') ) # # do something # else # # don't worry about the error @@ -259,7 +259,7 @@ class Chef # @return [Chef::Resource] The new resource. # # @example - # declare_resource(:file, '/x/y.txy', caller[0]) do + # declare_resource(:file, '/x/y.txt', caller[0]) do # action :delete # end # # Equivalent to @@ -293,7 +293,7 @@ class Chef # @return [Chef::Resource] The new resource. # # @example - # build_resource(:file, '/x/y.txy', caller[0]) do + # build_resource(:file, '/x/y.txt', caller[0]) do # action :delete # end # |