Skip to content

Commit

Permalink
tools/buildall.elv: Always remove existing zip files.
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaq committed Sep 4, 2024
1 parent ce19c91 commit 1d97e88
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tools/buildall.elv
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,11 @@ fn main {|go-pkg dst-dir &name=elvish &variant='' &keep-bin=$false|
# fixed point in time to make the archive files reproducible.
touch -d 2000-01-01T00:00:00Z $bin-name-in-archive
if (eq $os windows) {
# If the zip file already exists, the zip command below will add the
# binary to the existing file. This is not the behavior we want, so always
# remove the zip file first. Passing -f makes the command succeed even if
# the file doesn't exist.
rm -f $archive-name
zip -q $archive-name $bin-name-in-archive
} else {
# If we create a .tar.gz file directly with the tar command, the
Expand Down

0 comments on commit 1d97e88

Please sign in to comment.