Empty bundles are not useless
- From
- R. Lemos <rslemos@gmail.com>
- Date
- Jul 14, 2020, 13:58 UTC
- Message-ID
- <CAM6_cxzzWJQpw9akM=JZAnZ0LrPBCPX+q1da8_24vOJexCKeHA@mail.gmail.com>
When working disconnected (sending bundles back and forth) it is useful to make bundles like this:
$ git bundle create /tmp/my.bundle master ^disconnected/master
This way I pack all new commits since the last updated from `disconnected` remote.
But if my local copy is up-to-date, git bundle refuses to create an empty bundle, since there are no commits to send.
However it would be nice to at least send the information that my local branch `master` is up-to-date. That is, the bundle would just convey that my local `master` points to a given commit (even though this commit is already on the remote site). This way, when I upload this bundle to the remote site, then bring back changes made there, the remote site will know which commits I already have.
Thanks. Rodrigo Lemos