Skip to content

Commit

Permalink
Ensure index repos can be deleted on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
mosteo committed Jun 14, 2024
1 parent bd25511 commit 386da16
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions src/alire/alire-index_on_disk.adb
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,11 @@ package body Alire.Index_On_Disk is
------------

function Delete (This : Index'Class) return Outcome is
use Ada.Directories;
package Adirs renames Ada.Directories;
begin
if Exists (This.Metadata_Directory) then
if Kind (This.Metadata_Directory) = Ada.Directories.Directory then
Delete_Tree (This.Metadata_Directory);
if Adirs.Exists (This.Metadata_Directory) then
if Adirs.Kind (This.Metadata_Directory) in Adirs.Directory then
Directories.Delete_Tree (This.Metadata_Directory);
Trace.Debug ("Metadata dir deleted: " & This.Metadata_Directory);
else
return Outcome_Failure
Expand Down
2 changes: 1 addition & 1 deletion src/alire/alire-version.ads
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ private
-- be replaced by `alr build` with the current commit, and appended with
-- "_or_later" after build.

Current_Str : constant String := "2.1-dev";
Current_Str : constant String := "2.1-dev+bd25511f_or_later";
-- 2.0.0: alr settings refactor and minor fixes
-- 2.0.0-rc1: release candidate for 2.0
-- 2.0.0-b1: first public release on the 2.0 branch
Expand Down

0 comments on commit 386da16

Please sign in to comment.