[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [elpa] master 872014e: Prevent accidental deletion of .git

From: Stefan Monnier
Subject: Re: [elpa] master 872014e: Prevent accidental deletion of .git
Date: Sun, 08 Nov 2015 20:58:09 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

> +# Use && after the cd commands, not ;, to ensure the build fails
> +# immediately if the directory $(ARCHIVE_TMP)/packages does not exist.
> +# For process-archive this is crucial; otherwise batch-make-archive in
> +# archive-contents.el will interpret directories in the current
> +# directory as unreleased packages, and recursively delete them,
> +# including .git.  Prior to using &&, running "make process-archive"
> +# could silently delete all local git history!

Actually, I think the problem is in the code which does the deletion: it
should only do the delete files it positively knows should be deleted,
rather than deleting any files which seem to be out of place.

Once we change the handling of :core in elpa/admin/archive-contents.el
so that it sets up symlinks rather than performing copies, we should at
least be able to make the deletion less dangerous, e.g. by only deleting
symlinks and empty directories (so even if the deletion was erroneous,
no actual file contents was destroyed along the way).

Fabián, any news on this?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]