Skip to content

Commit

Permalink
Merge pull request #19 from chef-cookbooks/ap/move-not-rename
Browse files Browse the repository at this point in the history
Use move to avoid cross-device error
  • Loading branch information
srenatus committed Apr 5, 2016
2 parents 56eb907 + b80d840 commit 26d1985
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions libraries/profile.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# encoding: utf-8
require 'tempfile'
require 'uri'
require 'fileutils'

# `compliance_profile` custom resource to collect and run Chef Compliance
# profiles
Expand Down Expand Up @@ -59,8 +60,7 @@ class ComplianceProfile < Chef::Resource
path = tar_path
directory(::Pathname.new(path).dirname.to_s).run_action(:create)

::File.rename(tf.path, path)
# tf.unlink
FileUtils.move(tf.path, path)
end
end

Expand Down
2 changes: 1 addition & 1 deletion metadata.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@
source_url 'https://github.com/chef-cookbooks/audit' if defined?(:source_url)
issues_url 'https://github.com/chef-cookbooks/audit/issues' if defined?(:issues_url)

version '0.3.2'
version '0.3.3'

0 comments on commit 26d1985

Please sign in to comment.