aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.pgm
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'stable-6.4' into stable-6.5Matthias Sohn2023-10-132-0/+7
|\ | | | | | | | | | | | | | | | | | | * stable-6.4: PackConfig: fix @since tags Remove unused API problem filters Add support for git config repack.packKeptObjects Do not exclude objects in locked packs from bitmap processing Change-Id: I2951d01f5f4581bee20079508cd8ee6ca8554f1f
| * Merge branch 'stable-6.3' into stable-6.4Matthias Sohn2023-10-132-0/+7
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.3: PackConfig: fix @since tags Remove unused API problem filters Add support for git config repack.packKeptObjects Do not exclude objects in locked packs from bitmap processing Change-Id: I4b94a2b79941c085fa2f62246e8e879aaa85cd3f
| | * Merge branch 'stable-6.2' into stable-6.3Matthias Sohn2023-10-132-0/+7
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.2: PackConfig: fix @since tags Remove unused API problem filters Add support for git config repack.packKeptObjects Do not exclude objects in locked packs from bitmap processing Change-Id: I22b89bf00dcef26b2096d25397aa9a57a745a92b
| | | * Merge branch 'stable-6.1' into stable-6.2Matthias Sohn2023-10-132-0/+7
| | | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.1: PackConfig: fix @since tags Remove unused API problem filters Add support for git config repack.packKeptObjects Do not exclude objects in locked packs from bitmap processing Change-Id: Ib4e4fe407dce334c7537bf278baa39db93aa2f09
| | | | * Merge branch 'stable-6.0' into stable-6.1Matthias Sohn2023-10-132-0/+7
| | | | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.0: PackConfig: fix @since tags Remove unused API problem filters Add support for git config repack.packKeptObjects Do not exclude objects in locked packs from bitmap processing Change-Id: I0c9c0b3c206cac03a93b30eda348177a4de35c36
| | | | | * Merge branch 'stable-5.13' into stable-6.0Matthias Sohn2023-10-132-0/+7
| | | | | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-5.13: PackConfig: fix @since tags Remove unused API problem filters Add support for git config repack.packKeptObjects Do not exclude objects in locked packs from bitmap processing Change-Id: Ifeaa4b4f0c5944d4ecd3042be429833ff72b43ed
| | | | | | * Do not exclude objects in locked packs from bitmap processingLuca Milanesio2023-10-122-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Packfiles having an equivalent .keep file are associated with in-flight pushes that haven't been completed, with potentially a set of git objects not yet referenced by a ref. If the Git client is not up-to-date, it may result in pushing a packfile, generating a <packfile>.keep on the server, which may also contain existing commits due to the lack of Git protocol negotiation in the git-receive-pack. The Git protocol negotiation is the phase where the client and the server exchange the list of refs they have for trying to find a common base and minimise the amount of objects to be transferred. The repack phase in GC was previously skipping all objects that were contained in all packfiles having a <packfile>.keep file associated (aka "locked packfiles"), which did not take into consideration the fact that excluding the existing commits would have resulted in the generation of an invalid bitmap file. The code for excluding the objects in the locked packfiles was written well before the bitmap was introduced, hence could not consider a use case that did not exist at that time. However, when the bitmap was introduced, the exclusion of locked packfiles was not changed, hence creating a potential problem. The issue went unnoticed for many years because the bitmap generation was disabled when JGit noticed any locked packfiles; however, the bitmaps are enabled again since Id722e68d9f , and the the issue is now visible and is impacting the GC repack phase. Introduce the '--pack-kept-objects' option in GC for including the objects contained in the locked packfiles during the repack phase, which is not an issue because of the following: - If there are any existing commits duplicated in the packfiles they will be just considered once anyway because the repack doesn't generate duplicates in the output packfile. - If there are any new commits that do not have any ref pointing to them, they will be automatically excluded from the output repacked packfile. The same identical solution is adopted in the C implementation of git in repack.c. Because the locked packfile is not pruned, any new commits not pointed by any refs will remain in the repository and there will not be any accidental pruning or object loss as it is today before this change. As a side-effect of this change, it is now potentially possible to still have duplicate BLOBs after GC when the keep packfile contained existing objects. However, it is way better to keep the duplication until the next GC phase rather than omitting existing objects from repacking and, therefore generating an invalid bitmap and incorrect packfile. Bug: 582292 Bug: 582455 Change-Id: Ide3445e652fcf256a7912f881cb898897c99b8f8
| | | | | | * Prepare 5.13.3-SNAPSHOT buildsMatthias Sohn2023-06-223-43/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I02b9388c8bc1c266bb29b4502504d137dd42142f
| | | | | | * JGit v5.13.2.202306221912-rv5.13.2.202306221912-rMatthias Sohn2023-06-223-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: Id0ee779fba85a6d5557f6319969adb2c74feebcf
* | | | | | | Prepare 6.5.1-SNAPSHOT buildsMatthias Sohn2023-03-073-46/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Idd9977ac08a339906e33beb73f57f8f6885ad86f
* | | | | | | JGit v6.5.0.202303070854-rv6.5.0.202303070854-rMatthias Sohn2023-03-073-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: I8da37ead0bd527bc4990ed5f8d5d4fb4f4d5cf01
* | | | | | | Prepare 6.5.0-SNAPSHOT buildsMatthias Sohn2023-03-013-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I313e3deed8fa00df0406b3d7b73e5b643dc25a05
* | | | | | | JGit v6.5.0.202302281825-rc1v6.5.0.202302281825-rc1Matthias Sohn2023-03-013-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: I1eb2e87b70c2da1dc81468cdc7ecf7dbd21d4190
* | | | | | | Prepare 6.5.0-SNAPSHOT buildsMatthias Sohn2023-03-013-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ie95ce8fcc2a570505d23d5a1642e33c041212260
* | | | | | | JGit v6.5.0.202302221508-m3v6.5.0.202302221508-m3Matthias Sohn2023-02-223-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: I00bf91823e2fe6503d52ae23bc1854f0b1d66dbd
* | | | | | | Merge branch 'stable-6.4'Matthias Sohn2023-02-201-6/+12
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.4: Fix getPackedRefs to not throw NoSuchFileException Add pack options to preserve and prune old pack files Allow to perform PackedBatchRefUpdate without locking loose refs Document option "core.sha1Implementation" introduced in 59029aec Change-Id: I36051c623fcd480aa80ed32b4e89f9bdd1b798e0
| * | | | | | Merge branch 'stable-6.3' into stable-6.4Matthias Sohn2023-02-201-6/+12
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.3: Fix getPackedRefs to not throw NoSuchFileException Add pack options to preserve and prune old pack files Allow to perform PackedBatchRefUpdate without locking loose refs Document option "core.sha1Implementation" introduced in 59029aec Change-Id: I1073098fb06eabafdb3c5e7fcf44d55b86a1b152
| | * | | | | Merge branch 'stable-6.2' into stable-6.3Matthias Sohn2023-02-201-6/+12
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.2: Fix getPackedRefs to not throw NoSuchFileException Add pack options to preserve and prune old pack files Allow to perform PackedBatchRefUpdate without locking loose refs Document option "core.sha1Implementation" introduced in 59029aec Change-Id: I765c7302ce84a6a9c28fdef29da2bfaa49477c6e
| | | * | | | Merge branch 'stable-6.1' into stable-6.2Matthias Sohn2023-02-161-6/+12
| | | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.1: Fix getPackedRefs to not throw NoSuchFileException Add pack options to preserve and prune old pack files Allow to perform PackedBatchRefUpdate without locking loose refs Document option "core.sha1Implementation" introduced in 59029aec Change-Id: Id32683d5f506e082d39af269803bccee0280cc27
| | | | * | | Merge branch 'stable-6.0' into stable-6.1Matthias Sohn2023-02-161-6/+12
| | | | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-6.0: Add pack options to preserve and prune old pack files Allow to perform PackedBatchRefUpdate without locking loose refs Document option "core.sha1Implementation" introduced in 59029aec Change-Id: I876a38c2de8b7d5eaacd00e36b85599f88173221
| | | | | * | Merge branch 'stable-5.13' into stable-6.0Matthias Sohn2023-02-161-6/+12
| | | | | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-5.13: Add pack options to preserve and prune old pack files Allow to perform PackedBatchRefUpdate without locking loose refs Document option "core.sha1Implementation" introduced in 59029aec Change-Id: I423f410578f5bbe178832b80fef8998a5372182c
| | | | | | * Add pack options to preserve and prune old pack filesMatthias Sohn2023-02-111-6/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the options - pack.preserveOldPacks - pack.prunePreserved This allows to configure in git config if old packs should be preserved during gc and pruned during the next gc. The original implementation in 91132bb0 only allows to set these options using the API. Change-Id: I5b23ab4f317d12f5ccd234401419913e8263cc9a
| | | | | | * Prepare 5.13.2-SNAPSHOT buildsMatthias Sohn2022-06-143-43/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I4862e5d80a7d95a1a119d06306e3f6927445d1d3
| | | | | | * JGit v5.13.1.202206130422-rv5.13.1.202206130422-rMatthias Sohn2022-06-133-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: Ife74d64e8171c68dbf08271492c0ac852a6dc51c
| | | | * | | Prepare 6.1.1-SNAPSHOT buildsMatthias Sohn2022-03-083-46/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ifc80355025d8459245843be1c24dc5a286913e77
| | | | * | | JGit v6.1.0.202203080745-rv6.1.0.202203080745-rMatthias Sohn2022-03-083-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I8766ed400020c9571f321bbbfe34b0688af0107d Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| | | | * | | Prepare 6.1.0-SNAPSHOT buildsMatthias Sohn2022-03-023-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I525fc1258a729c36d63fdb3c8170e9f04ad55cec
| | | | * | | JGit v6.1.0.202203021511-rc1v6.1.0.202203021511-rc1Matthias Sohn2022-03-023-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I4c75a58fd76102e773af4f1f8a1487d5e7ffc7cf Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| | | * | | | Prepare 6.2.1-SNAPSHOT buildsMatthias Sohn2022-06-073-46/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I4a0f3919ff43a3b9fafa85b8ecec2d760b7eb161
| | | * | | | JGit v6.2.0.202206071550-rv6.2.0.202206071550-rMatthias Sohn2022-06-073-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: Ib4ae85a0cabcc9cb867f2c85034d72fb676a500a
| | | * | | | Prepare 6.2.0-SNAPSHOT buildsMatthias Sohn2022-06-063-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Id2ad8d5b561620723b2c52c86909321d628de12f
| | | * | | | Merge branch 'master' into stable-6.2Andrey Loskutov2022-06-034-150/+207
| | | |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: Adapt diff- and merge tool code for PGM and EGit usage Teach JGit to handle external diff/merge tools defined in .gitattributes Change-Id: I3aefc14160caaac859bd3548460dd755ebe42fc5
| | | * | | | | JGit v6.2.0.202206011217-rc1v6.2.0.202206011217-rc1Matthias Sohn2022-06-013-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: Id9639b466583d8c373ef700402cb685ce4a8ee15
| * | | | | | | Prepare 6.4.1-SNAPSHOT buildsMatthias Sohn2022-11-303-46/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I860bfde113c05015c41304c4a77c44c224bd0923
| * | | | | | | JGit v6.4.0.202211300538-rv6.4.0.202211300538-rMatthias Sohn2022-11-303-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: If4001b255a209849b4acabd2083164d0794f00c4
| * | | | | | | Prepare 6.4.0-SNAPSHOT buildMatthias Sohn2022-11-233-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I41c4f73472bb47d8f9d2d117d17e11bba4802928
| * | | | | | | JGit v6.4.0.202211231055-rc1v6.4.0.202211231055-rc1Matthias Sohn2022-11-233-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: Ia34696d07568b298544ee2cdc6f4b6746774bb82
* | | | | | | | [pgm] Fetch-CLI: add support for shallowHarald Weiner2023-01-246-0/+112
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for shallow cloning. The CloneCommand and the FetchCommand now have the new options --depth, --shallow-since and --shallow-exclude to tell the server that the client doesn't want to download the complete history. Bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=475615 Change-Id: I8f113bed25dd6df64f2f95de6a59d4675ab8a903
* | | | | | | | Prepare 6.5.0-SNAPSHOT buildsMatthias Sohn2022-11-233-46/+46
|/ / / / / / / | | | | | | | | | | | | | | | | | | | | | Change-Id: I4238b6181e96e22e540cf34802a332f868cb6dfb
* | | | | | | [pgm] Add options --name-only, --name-status to diff, log, showalerthak2022-11-235-8/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ib218bd2ccbd7990feca4c35d8c8dc34d4a8291e6
* | | | | | | [pgm] Ensure UploadPack is closed to fix resource leakMatthias Sohn2022-11-211-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I40da4b331012dd1c6f4b497e46c973fd776b737f
* | | | | | | pgm/BUILD: Add dependencty to java EWAHIvan Frade2022-10-051-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A fetch to a locally run daemon triggers a runtime exception: Listening on localhost/127.0.0.1:9418 java.lang.NoClassDefFoundError: com/googlecode/javaewah/EWAHCompressedBitmap Add javaEWAH in the deps of the PGM library. To reproduce: 0. Assume a git repo in <dir-with-repos>/a-repo 1. Run daemon e.g.: $ bazel run //org.eclipse.jgit.pgm:jgit -- daemon --export-all=true --listen localhost --enable upload-pack <dir-with-repos> 2. Fetch: $ git clone git://0.0.0.0:9418/a-repo Change-Id: I503f9fe45347a5891c3f3de0452b7f300b1e8206
* | | | | | | Prepare 6.4.0-SNAPSHOT buildsMatthias Sohn2022-09-143-46/+46
|/ / / / / / | | | | | | | | | | | | | | | | | | Change-Id: I47ca5f1d0263caa0bfc7c303042360c6c5ac4dec
* | | | | | Prepare 6.3.1-SNAPSHOT buildsMatthias Sohn2022-09-123-46/+46
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I44e159eca4131880d74d3078060e7e20f9b5ce76
* | | | | | JGit v6.3.0.202209071007-rv6.3.0.202209071007-rMatthias Sohn2022-09-073-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: Iea3fae9f6f6c5fb0a79f7684334a3e0059738c4f
* | | | | | JGit v6.3.0.2022009070944-rMatthias Sohn2022-09-073-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: I3cc78dbcf8c7970e80bf1499751611110ec2b30b
* | | | | | Prepare 6.3.0-SNAPSHOT buildsMatthias Sohn2022-08-173-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ie398b651c5308ec86812bf01fcc563d3e679c828
* | | | | | JGit v6.3.0.202208161710-m3v6.3.0.202208161710-m3Matthias Sohn2022-08-163-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: I0954d11a1f35eff196b157df3aa8386476c48a7e
* | | | | | Fix DefaultCharset bug pattern flagged by error proneDavid Ostrovsky2022-06-172-5/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | See more details in: [1]. [1] https://errorprone.info/bugpattern/DefaultCharset Change-Id: I3de0be57a2d74490a5b4e66801e9767b38f13bf9
* | | | | | Use SystemReader#getDefaultCharset to read console inputDavid Ostrovsky2022-06-171-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In I986f97a410 SystemReader.getDefaultCharset() that provides the locale-dependent charset the way JEP 400 recommends. Change-Id: I30560ac47e450070e3864325d153d45f1a66882c