Skip to content

Commit

Permalink
Make sure update command can clean older version of Pakku dist if…
Browse files Browse the repository at this point in the history
… needed
  • Loading branch information
hythm7 committed Aug 15, 2023
1 parent 5837297 commit 6bcf59a
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions lib/Pakku/Command/Update.rakumod
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,6 @@ multi method fly (

my %state = self.state: :updates;

%state.values
==> grep( *.<cln> )
==> map( *.<meta> )
==> my @clean;

eager @spec.sort
==> map( -> $spec { Pakku::Spec.new: $spec } )
==> map( -> $spec {
Expand Down Expand Up @@ -187,7 +182,14 @@ multi method fly (
}

if $clean {
samewith 'remove', spec => @clean.map( *.Str ) if @clean;

self.state( :!updates ).values
==> grep( *.<cln> )
==> map( *.<meta>.Str )
==> my @spec;

samewith 'remove', :@spec if @spec;

}
}
}

0 comments on commit 6bcf59a

Please sign in to comment.