Solve styling and metadata issues

This commit is contained in:
L. E. Segovia 2017-11-28 13:34:50 +00:00
parent f3355b2a2c
commit 8386b9384c
2 changed files with 6 additions and 3 deletions

View File

@ -71,7 +71,7 @@ module Hbc
command.run("/bin/mv", args: [target, source], sudo: true)
end
add_altname_metadata(target, source.basename, command: command)
add_altname_metadata(source, target.basename, command: command)
end
def delete(target, force: false, command: nil, **_)

View File

@ -452,8 +452,11 @@ module Hbc
ohai "Purging files for version #{@cask.version} of Cask #{@cask}"
# versioned staged distribution
staged_path = version_is_latest? ?
backup_path(@cask.staged_path) : @cask.staged_path
if version_is_latest?
staged_path = backup_path(@cask.staged_path)
else
staged_path = @cask.staged_path
end
gain_permissions_remove(staged_path) if !staged_path.nil? && staged_path.exist?