[Top][All Lists]

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

Re: policy discussion on bundling ELPA packages in the emacs tarball

From: Dmitry Gutov
Subject: Re: policy discussion on bundling ELPA packages in the emacs tarball
Date: Tue, 26 Jan 2021 03:57:15 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0

On 26.01.2021 00:00, Stephen Leake wrote:
Dmitry Gutov <dgutov@yandex.ru> writes:

On 24.01.2021 22:15, Eli Zaretskii wrote:
IMO, people who are interested only in packages bundled with Emacs
should not need to have ELPA on their local machines.  Not even one
checkout of ELPA should be needed.  They should just need to clone the
Emacs Git repository (modulo the submodules-related options), and
that's all.  Exactly like they do today: there's no need to clone ELPA
to have a fully functional clone of the Emacs Git repository.

Git allows one to check out one branch's contents, without the rest of
the repository.

Just to be clear, "checkout" means retrieve from a local git repository
into a directory tree; that is always a single branch.

I referred to doing only a partial download, of course.

So said people wouldn't need to download the whole of ELPA, if you
were worried about that.

"clone" and "add submodule" download from the remote repository.

"add submodule -b <branch>" specifies what branch to checkout, but still
downloads the whole repository.

Ah; "clone ... --single-branch --branch <branch>" allows downloading
only that branch into the local repository. But you can't specify more
than one branch, so that would be inconvenient for more than one bundled

And "git add submodule" does not accept --single-branch.

There is a pretty long description here: https://stackoverflow.com/questions/2144406/how-to-make-shallow-git-submodules, which I didn't have time to read whole.

But from a small experiment, here's what you can do:

git submodule add --depth 1 <repo> <new-module-path>
cd <new-module-path>
git fetch --depth 512 # or however more you need

There are also options like --shallow-since or --deepen.

reply via email to

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