Skip to content

Commit

Permalink
Remove empty arch-specific dirs during installation
Browse files Browse the repository at this point in the history
  • Loading branch information
apjanke committed Apr 14, 2019
1 parent 7c45c15 commit 8cc3c0d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions inst/+packajoozle/+internal/PkgManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,12 @@ function display_user_messages (this, rslt)
desc.name, err.message);
end_try_catch

# Tidy up the installation

if dir_is_empty (target.arch_dir)
rm_rf_safe (target.arch_dir);
endif

# Validate the installation

if dirempty (target.dir, {"packinfo", "doc"}) ...
Expand Down Expand Up @@ -508,6 +514,9 @@ function rm_rf_safe (path)
% ======================================================
% My special functions

function out = dir_is_empty (path)
out = isempty (packajoozle.internal.Util.readdir (path));
endfunction

% ======================================================
%
Expand Down

0 comments on commit 8cc3c0d

Please sign in to comment.