[Buildroot] [PATCH] Restore .git directory in git package downloads

Ricardo Martincoski ricardo.martincoski at gmail.com
Wed Apr 19 23:37:50 UTC 2017


James,

[Either I or my mail client did something stupid and the e-mail did not reach
the mailing list and the patchwork. Resending to the list]

On Wed, Apr 19, 2017 at 01:00 AM, James Balean wrote:
> +++ b/support/download/git
> @@ -85,10 +85,6 @@ if [ ${recurse} -eq 1 ]; then
>      _git submodule update --init --recursive
>  fi
>  
> -# We do not need the .git dir; we keep other .git files, in case they
> -# are the only files in their directory.
> -rm -rf .git

This patch cannot be applied as-is because:

- it would make the tarballs for git packages not reproducible as the contents
  now depend on the state of the remote server (i.e. in some cases a full clone
  is needed; assume a tarball is generated, then a new commit is created in the
  remote server in any branch, a new full clone with the same reference as
  version would include that new commit and therefore the tarball is different);

- it would make the tarballs for git packages much larger (gigabytes for some
  linux trees) as they now include the .git directory;

Of course I am not against the discussion looking for another solution.

Regards,
Ricardo


More information about the buildroot mailing list