]> source.dussan.org Git - jgit.git/log
jgit.git
8 years agoMerge branch 'stable-4.2' 77/66477/1
Matthias Sohn [Fri, 12 Feb 2016 10:15:19 +0000 (11:15 +0100)]
Merge branch 'stable-4.2'

* stable-4.2:
  NoteMapTest: Open TreeWalk instances in try-with-resource
  ObjectDirectoryTest: Fix warnings about variable hiding
  PackWriterTest: Open RevWalk in try-with-resource
  PatchIdDiffFormatterTest: Open Git and PatchIdDiffFormatter in try-with-resource
  PathSuffixFilterTest: Open TreeWalk in try-with-resource
  PostOrderTreeWalkTest: Open TreeWalk in try-with-resource
  PullCommandWithRebaseTest: Open RevWalk in try-with-resource
  PushCommandTest: Open Git instances in try-with-resource
  RacyGitTests: Open NameConflictTreeWalk in try-with-resource
  RecursiveMergerTest: Open TreeWalk and BufferedReader in try-with-resource
  ReflogConfigTest: refactor commit method to avoid variable hiding
  Update .mailmap
  RefDirectoryTest: Fix warning about member variable hiding
  ReflogResolveTest: Open Git instances in try-with-resource
  ReflogTest: Open Git instances in try-with-resource
  RepoCommandTest: Open Git instances in try-with-resource

Change-Id: I7964b699396629e31a9cc5600aedcf4be4e659a8
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoNoteMapTest: Open TreeWalk instances in try-with-resource 62/66462/1
David Pursehouse [Fri, 12 Feb 2016 05:12:25 +0000 (14:12 +0900)]
NoteMapTest: Open TreeWalk instances in try-with-resource

Change-Id: I70da0140fe087e7e69c28e9ddd125495d916ec1b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoObjectDirectoryTest: Fix warnings about variable hiding 61/66461/1
David Pursehouse [Fri, 12 Feb 2016 05:10:12 +0000 (14:10 +0900)]
ObjectDirectoryTest: Fix warnings about variable hiding

The variable and parameter named 'db' were hiding class members
with the same name.

Change-Id: I27017afdc5f49c38c6f5be494e7a21239ea601a7
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoPackWriterTest: Open RevWalk in try-with-resource 60/66460/1
David Pursehouse [Fri, 12 Feb 2016 05:09:02 +0000 (14:09 +0900)]
PackWriterTest: Open RevWalk in try-with-resource

Change-Id: Ic8ed941d096718e81c7ffeb166bcf7faaa2ff57d
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoPatchIdDiffFormatterTest: Open Git and PatchIdDiffFormatter in try-with-resource 59/66459/1
David Pursehouse [Fri, 12 Feb 2016 05:07:24 +0000 (14:07 +0900)]
PatchIdDiffFormatterTest: Open Git and PatchIdDiffFormatter in try-with-resource

Change-Id: I39e898e52c3d9dffaba9dabf11c085503fbc1acf
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoPathSuffixFilterTest: Open TreeWalk in try-with-resource 58/66458/1
David Pursehouse [Fri, 12 Feb 2016 05:02:49 +0000 (14:02 +0900)]
PathSuffixFilterTest: Open TreeWalk in try-with-resource

Change-Id: If0ee71f09a5464e27f0496dac364f8f9bb015eb6
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoPostOrderTreeWalkTest: Open TreeWalk in try-with-resource 57/66457/1
David Pursehouse [Fri, 12 Feb 2016 05:01:30 +0000 (14:01 +0900)]
PostOrderTreeWalkTest: Open TreeWalk in try-with-resource

Also remove unnecessary nesting in test methods.

Change-Id: Id59f8403c0a7b38ebb6b3a24814257cd59ea575d
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoPullCommandWithRebaseTest: Open RevWalk in try-with-resource 56/66456/1
David Pursehouse [Fri, 12 Feb 2016 04:57:34 +0000 (13:57 +0900)]
PullCommandWithRebaseTest: Open RevWalk in try-with-resource

Change-Id: I16f4d219e8b103d30149b2a94d3484424f3de84b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoPushCommandTest: Open Git instances in try-with-resource 55/66455/1
David Pursehouse [Fri, 12 Feb 2016 04:55:40 +0000 (13:55 +0900)]
PushCommandTest: Open Git instances in try-with-resource

Change-Id: I3a8e28a4097e868a34ee1b23256c7f28d570cd75
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRacyGitTests: Open NameConflictTreeWalk in try-with-resource 54/66454/1
David Pursehouse [Fri, 12 Feb 2016 04:50:54 +0000 (13:50 +0900)]
RacyGitTests: Open NameConflictTreeWalk in try-with-resource

Change-Id: Ic17b05fd7d056761b352168de97efb607a289276
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRecursiveMergerTest: Open TreeWalk and BufferedReader in try-with-resource 53/66453/1
David Pursehouse [Fri, 12 Feb 2016 04:48:54 +0000 (13:48 +0900)]
RecursiveMergerTest: Open TreeWalk and BufferedReader in try-with-resource

Change-Id: I381d535eb4ed7535ba8541c5320f81ce11d5b173
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoReflogConfigTest: refactor commit method to avoid variable hiding 52/66452/1
David Pursehouse [Fri, 12 Feb 2016 04:43:56 +0000 (13:43 +0900)]
ReflogConfigTest: refactor commit method to avoid variable hiding

The author and committer parameters were hiding class members of
the same name.

Since the passed in PersonIdent instances were being created from
the class members anyway, remove the parameters and instead create
the PersonIdent instances inline in the method.

Change-Id: I66b057df388835d57f332fdcbadb8a9f4e1094a4
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoUpdate .mailmap 51/66451/1
David Pursehouse [Fri, 12 Feb 2016 03:39:06 +0000 (12:39 +0900)]
Update .mailmap

- List names alphabetically by Firstname Surname
- Replace tabs with spaces
- Add missing name

Change-Id: Ib320dad316e0f6e3e95363c4d6a64744032db857
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRefDirectoryTest: Fix warning about member variable hiding 50/66450/1
David Pursehouse [Fri, 12 Feb 2016 03:30:46 +0000 (12:30 +0900)]
RefDirectoryTest: Fix warning about member variable hiding

The parameter name 'totalWork' was hiding a class member variable
of the same name.

Change-Id: I646525e82900e23ffabfc756bcf5052ef873656a
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoReflogResolveTest: Open Git instances in try-with-resource 49/66449/1
David Pursehouse [Fri, 12 Feb 2016 03:29:44 +0000 (12:29 +0900)]
ReflogResolveTest: Open Git instances in try-with-resource

Change-Id: I11ee38bfcf4951bf05a1632df08b1d074d38338b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoReflogTest: Open Git instances in try-with-resource 48/66448/1
David Pursehouse [Fri, 12 Feb 2016 03:26:58 +0000 (12:26 +0900)]
ReflogTest: Open Git instances in try-with-resource

Change-Id: I950b6f16148cfe11de729b04904f88d6e4c28b9a
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRepoCommandTest: Open Git instances in try-with-resource 47/66447/1
David Pursehouse [Fri, 12 Feb 2016 03:25:20 +0000 (12:25 +0900)]
RepoCommandTest: Open Git instances in try-with-resource

Change-Id: I171e84eeb7862e74761ba6c961f14c86beaba9e7
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoFix packaging of lfs bundles 44/66444/2
Matthias Sohn [Fri, 12 Feb 2016 01:06:04 +0000 (02:06 +0100)]
Fix packaging of lfs bundles

- pgm feature needs to include the lfs feature
- add the lfs feature to the jgit p2 repository

Change-Id: I6781d4e9d131b373c9f191d785495e88b906c671
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoAdd Attribute Macro Expansion 17/60617/11
Ivan Motsch [Tue, 17 Nov 2015 15:04:01 +0000 (16:04 +0100)]
Add Attribute Macro Expansion

Attributes MacroExpander implements macros used in git attributes. This
is implemented inside the TreeWalk using a lazy created MacroExpander.
In addition, the macro expander caches the global and info attributes
node in order to provide fast merge of attributes.

Change-Id: I2e69c9fc84e9d7fb8df0a05817d688fc456d8f00
Signed-off-by: Ivan Motsch <ivan.motsch@bsiag.com>
8 years agoMerge branch 'stable-4.2' 57/66257/1
Matthias Sohn [Tue, 9 Feb 2016 23:50:41 +0000 (00:50 +0100)]
Merge branch 'stable-4.2'

* stable-4.2:
  RepoProject: Fix warnings about variable hiding
  RepoTest: Open Git in try-with-resources
  RepositoryResolveTest: Open Git in try-with-resource
  RepositoryTestCase: Open autocloseable types in try-with-resource
  ResetCommandTest: Use Git member in testHardResetAfterSquashMerge
  ResolveMergerTest: Open Git in try-with-resource
  RevCommitListTest: Open Git and RevWalk in try-with-resource
  RevCommitParseTest: Open ObjectInserter.Formatter in try-with-resource
  RevObjectTest: Open RevWalk in try-with-resource
  RevTagParseTest: Open ObjectInserter.Formatter in try-with-resource
  RevertCommandTest: Open Git in try-with-resource
  SquashMessageFormatterTest: Open git in try-with-resource
  StatusCommandTest: Open Git in try-with-resource
  SubmoduleAddTest: Open Git in try-with-resource
  SymlinksTest: Open git and TreeWalk in try-with-resource
  T0003_BasicTest: Open autocloseable types in try-with-resource
  TextHashFunctions: Fix warnings about variable hiding
  TreeFilterTest: Open TreeWalk in try-with-resource
  TreeWalkJava7Test: Open TreeWalk in try-with-resource
  Fix diff for added and removed submodule

Change-Id: If3ecc63f6dfac55474d3c1dd2f4105371f3d24fb
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoMerge branch 'stable-4.1' into stable-4.2 56/66256/1
Matthias Sohn [Tue, 9 Feb 2016 23:44:58 +0000 (00:44 +0100)]
Merge branch 'stable-4.1' into stable-4.2

* stable-4.1:
  Fix diff for added and removed submodule

Change-Id: I37dd71ed19b06e9bbcffe37370081ab875c6d8d4
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoRepoProject: Fix warnings about variable hiding 89/65989/1
David Pursehouse [Fri, 5 Feb 2016 09:22:58 +0000 (18:22 +0900)]
RepoProject: Fix warnings about variable hiding

Method parameter names were hiding class members of the same
name.

Change-Id: I182f2715894ac4259b09a371cb4e0eb24f52518a
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRepoTest: Open Git in try-with-resources 84/65984/1
David Pursehouse [Fri, 5 Feb 2016 09:17:02 +0000 (18:17 +0900)]
RepoTest: Open Git in try-with-resources

Allocate a new Git for each part of the test, rather than
reassigning to the same variable.

Change-Id: Ic83778bbff0b2f57d37b95aef70324859d42cd58
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRepositoryResolveTest: Open Git in try-with-resource 81/65981/1
David Pursehouse [Fri, 5 Feb 2016 09:14:26 +0000 (18:14 +0900)]
RepositoryResolveTest: Open Git in try-with-resource

Change-Id: Ibb612f3d8fd0f9913291430474311d9da62f4e6f
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRepositoryTestCase: Open autocloseable types in try-with-resource 79/65979/1
David Pursehouse [Fri, 5 Feb 2016 09:12:05 +0000 (18:12 +0900)]
RepositoryTestCase: Open autocloseable types in try-with-resource

ObjectInserter.Formatter and Git are autocloseable and can be
opened in try-with-resource to prevent a resource leak warning.

Change-Id: I48c4001aaa7d9c1e36369e9799bfbb7c3bb46d8b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoResetCommandTest: Use Git member in testHardResetAfterSquashMerge 77/65977/1
David Pursehouse [Fri, 5 Feb 2016 08:36:05 +0000 (17:36 +0900)]
ResetCommandTest: Use Git member in testHardResetAfterSquashMerge

Use the class member instance of the Git rather than creating
a new one in the test. This makes it consistent with the other
tests in the module.

Change-Id: Ibe822ded76a80b94922e92bbc6f5d90bcc52f8a3
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoResolveMergerTest: Open Git in try-with-resource 76/65976/1
David Pursehouse [Fri, 5 Feb 2016 08:31:11 +0000 (17:31 +0900)]
ResolveMergerTest: Open Git in try-with-resource

Change-Id: Ic378ec25c4a3ea4354ee643029f87e46b6449ed4
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRevCommitListTest: Open Git and RevWalk in try-with-resource 75/65975/1
David Pursehouse [Fri, 5 Feb 2016 08:26:03 +0000 (17:26 +0900)]
RevCommitListTest: Open Git and RevWalk in try-with-resource

Change-Id: I4ba273a364a12f82a3b3b06ba050bc633411daf6
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRevCommitParseTest: Open ObjectInserter.Formatter in try-with-resource 74/65974/1
David Pursehouse [Fri, 5 Feb 2016 08:20:51 +0000 (17:20 +0900)]
RevCommitParseTest: Open ObjectInserter.Formatter in try-with-resource

Change-Id: Iaa87c51bc19b4fa832393c11db20b69865d30d48
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRevObjectTest: Open RevWalk in try-with-resource 73/65973/1
David Pursehouse [Fri, 5 Feb 2016 08:17:12 +0000 (17:17 +0900)]
RevObjectTest: Open RevWalk in try-with-resource

Change-Id: I19bcbb2f12036c5043436f3d544ccefbb7385b8d
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRevTagParseTest: Open ObjectInserter.Formatter in try-with-resource 72/65972/1
David Pursehouse [Fri, 5 Feb 2016 08:15:19 +0000 (17:15 +0900)]
RevTagParseTest: Open ObjectInserter.Formatter in try-with-resource

Change-Id: I2341977223be1dc5252492f4775626122f56496b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRevertCommandTest: Open Git in try-with-resource 71/65971/1
David Pursehouse [Fri, 5 Feb 2016 08:12:57 +0000 (17:12 +0900)]
RevertCommandTest: Open Git in try-with-resource

Change-Id: I659adbb0a6f741c4c6f615c8a24b4603c3f6681e
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoSquashMessageFormatterTest: Open git in try-with-resource 70/65970/1
David Pursehouse [Fri, 5 Feb 2016 08:05:05 +0000 (17:05 +0900)]
SquashMessageFormatterTest: Open git in try-with-resource

Change-Id: Ife94d1f0279ed3671a9bca79fb26c0403549fa17
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoStatusCommandTest: Open Git in try-with-resource 69/65969/1
David Pursehouse [Fri, 5 Feb 2016 08:03:25 +0000 (17:03 +0900)]
StatusCommandTest: Open Git in try-with-resource

Change-Id: Id13ad9fa3157d0479da12fb8184437be3ca8c948
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoSubmoduleAddTest: Open Git in try-with-resource 64/65964/1
David Pursehouse [Fri, 5 Feb 2016 05:11:54 +0000 (14:11 +0900)]
SubmoduleAddTest: Open Git in try-with-resource

Change-Id: I1276ce206e891729adfa681e00952ca0ba6ffc53
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoSymlinksTest: Open git and TreeWalk in try-with-resource 63/65963/1
David Pursehouse [Fri, 5 Feb 2016 05:05:22 +0000 (14:05 +0900)]
SymlinksTest: Open git and TreeWalk in try-with-resource

Change-Id: I0fd1933e843375029fa795447b688f23a893f84b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoT0003_BasicTest: Open autocloseable types in try-with-resource 62/65962/1
David Pursehouse [Fri, 5 Feb 2016 02:51:27 +0000 (11:51 +0900)]
T0003_BasicTest: Open autocloseable types in try-with-resource

FileRepository and ObjectInserter.Formatter are autocloseable, so
use try-with-resource for these.

Remove suppression of unused variable warning that is no longer
necessary.

Change-Id: I270829f0a4030083c9599eb5785b0145dc590ed8
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoTextHashFunctions: Fix warnings about variable hiding 61/65961/1
David Pursehouse [Fri, 5 Feb 2016 02:46:45 +0000 (11:46 +0900)]
TextHashFunctions: Fix warnings about variable hiding

The local variables/arguments named 'db' were hiding the member
variable of the same name in the superclass TextBuiltin.

Change-Id: Ic49dcb7cc2a1b3fb46ad78450042c8c8fb464a80
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoTreeFilterTest: Open TreeWalk in try-with-resource 60/65960/1
David Pursehouse [Fri, 5 Feb 2016 02:44:12 +0000 (11:44 +0900)]
TreeFilterTest: Open TreeWalk in try-with-resource

Change-Id: If100a66e544926bcffe9a9a0b31bfd4806902864
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoTreeWalkJava7Test: Open TreeWalk in try-with-resource 59/65959/1
David Pursehouse [Fri, 5 Feb 2016 02:42:44 +0000 (11:42 +0900)]
TreeWalkJava7Test: Open TreeWalk in try-with-resource

Change-Id: I99a483c482b5395653b0d57b368ec1b5fdba450c
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoAdd support for HEAD requests to HttpClientConnection 71/65771/2
Matthias Sohn [Wed, 3 Feb 2016 10:34:35 +0000 (11:34 +0100)]
Add support for HEAD requests to HttpClientConnection

Change-Id: I501f37e06b686a3a0bb5fd857dd72e424da91d3e
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoAllow to reuse disableSslVerify method, move it to HttpSupport 77/64677/5
Saša Živkov [Tue, 19 Jan 2016 16:52:19 +0000 (17:52 +0100)]
Allow to reuse disableSslVerify method, move it to HttpSupport

The disableSslVerify method will be used in the follow up change.

Change-Id: Ie00b5e14244a9a036cbdef94768007f1c25aa8d3
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoSupport LFS protocol and a file system based LFS storage 77/52177/16
Matthias Sohn [Tue, 22 Dec 2015 15:11:43 +0000 (16:11 +0100)]
Support LFS protocol and a file system based LFS storage

Implement LfsProtocolServlet handling the "Git LFS v1 Batch API"
protocol [1]. Add a simple file system based LFS content store and the
debug-lfs-store command to simplify testing.

Introduce a LargeFileRepository interface to enable additional storage
implementation while reusing the same protocol implementation.

At the client side we have to configure the lfs.url, specify that
we use the batch API and we don't use authentication:

  [lfs]
  url = http://host:port/lfs
  batch = true
  [lfs "http://host:port/lfs"]
  access = none

the git-lfs client appends the "objects/batch" to the lfs.url.

Hard code an Authorization header in the FileLfsRepository.getAction
because then git-lfs client will skip asking for credentials. It will
just forward the Authorization header from the response to the
download/upload request.

The FileLfsServlet supports file content storage for "Large File
Storage" (LFS) server as defined by the Github LFS API [2].

- upload and download of large files is probably network bound hence use
  an asynchronous servlet for good scalability
- simple object storage in file system with 2 level fan-out
- use LockFile to protect writing large objects against multiple
  concurrent uploads of the same object
- to prevent corrupt uploads the uploaded file is rejected if its hash
  doesn't match id given in URL

The debug-lfs-store command is used to run the LfsProtocolServlet and,
optionally, the FileLfsServlet which makes it easier to setup a
local test server.

[1]
https://github.com/github/git-lfs/blob/master/docs/api/http-v1-batch.md
[2] https://github.com/github/git-lfs/tree/master/docs/api

Bug: 472961
Change-Id: I7378da5575159d2195138d799704880c5c82d5f3
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Signed-off-by: Sasa Zivkov <sasa.zivkov@sap.com>
8 years agoAdd com.google.gson 2.2.4.v201311231704 to target platform 54/52354/9
Matthias Sohn [Fri, 17 Jul 2015 21:57:46 +0000 (23:57 +0200)]
Add com.google.gson 2.2.4.v201311231704 to target platform

We will use gson to implement the LFS REST API.

CQ: 9966
Change-Id: I7feb6b2b8f7b736888370aad94e4c436ae6014bb
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoImplement SHA-256 abstraction 76/52176/12
Matthias Sohn [Fri, 17 Jul 2015 14:22:56 +0000 (16:22 +0200)]
Implement SHA-256 abstraction

The Large File Storage extension specified by GitHub [1] uses SHA-256 to
compute the ID of large files stored by the extension. Hence implement a
SHA-256 abstraction similar to the SHA-1 abstraction used by JGit.

[1] https://git-lfs.github.com/

Bug: 470333
Change-Id: I3a95954543c8570d73929e55f4a884b55dbf1b7a
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoFix diff for added and removed submodule 03/65903/2
Hugo Arès [Thu, 4 Feb 2016 13:55:20 +0000 (08:55 -0500)]
Fix diff for added and removed submodule

Since If13f7b406, submodule difference are shown as a hunk. The issue
was that added and removed submodule were considered as Edit.REPLACE
instead of Edit.INSERT and Edit.DELETE in the DiffFormatter result.

Change-Id: I4330c2aa3f10e29d7d6b0b2e5286e59293a06239
Signed-off-by: Hugo Arès <hugo.ares@ericsson.com>
8 years agoRemove unused API problem filters 63/65763/1
Matthias Sohn [Wed, 3 Feb 2016 09:39:08 +0000 (10:39 +0100)]
Remove unused API problem filters

Change-Id: I8b1c99b108b4cea6356e0a62e6bfc0731df44cf5
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoMerge branch 'stable-4.2' 62/65762/1
Matthias Sohn [Wed, 3 Feb 2016 09:30:38 +0000 (10:30 +0100)]
Merge branch 'stable-4.2'

* stable-4.2:
  DirCacheCheckoutTest: Open Git and TreeWalk in try-with-resource
  CommitCommand: Remove declaration of unthrown exception
  Branch: Fix variable hiding warning
  ApplyCommandTest: Open Git in try-with-resource
  PackFileTest: Open ObjectInserter.Formatter in try-with-resource

Change-Id: I8484b10fad5a4c35fcfaedc1cdf8ccf97471618e
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoDirCacheCheckoutTest: Open Git and TreeWalk in try-with-resource 37/65637/1
David Pursehouse [Tue, 2 Feb 2016 09:30:30 +0000 (18:30 +0900)]
DirCacheCheckoutTest: Open Git and TreeWalk in try-with-resource

Change-Id: Icc8eda841e6a437e1acf3438525014e7c46d5eb2
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoCommitCommand: Remove declaration of unthrown exception 36/65636/1
David Pursehouse [Tue, 2 Feb 2016 09:27:47 +0000 (18:27 +0900)]
CommitCommand: Remove declaration of unthrown exception

Change-Id: I1795b1e510ab170f062ee6c5988d7a7567abe260
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoBranch: Fix variable hiding warning 35/65635/1
David Pursehouse [Tue, 2 Feb 2016 09:25:55 +0000 (18:25 +0900)]
Branch: Fix variable hiding warning

The Branch class has a member named 'branch', which was being
hidden by the local variable of the same name used in a for-loop.

Change-Id: I334092010a9c80686fb79713852d4bfa166ce12f
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoApplyCommandTest: Open Git in try-with-resource 34/65634/1
David Pursehouse [Tue, 2 Feb 2016 09:22:32 +0000 (18:22 +0900)]
ApplyCommandTest: Open Git in try-with-resource

Also, add missing braces around if-block.

Change-Id: I9390b2c7d5c4507923b6f06271a070dc868534e5
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoPackFileTest: Open ObjectInserter.Formatter in try-with-resource 33/65633/1
David Pursehouse [Tue, 2 Feb 2016 09:20:38 +0000 (18:20 +0900)]
PackFileTest: Open ObjectInserter.Formatter in try-with-resource

Change-Id: I9c56b5efdb9c13b929073a786092a707fca21281
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoMerge branch 'stable-4.2' 31/65531/1
David Pursehouse [Mon, 1 Feb 2016 01:30:36 +0000 (10:30 +0900)]
Merge branch 'stable-4.2'

* stable-4.2:
  FileTreeIteratorTest: Open Git and RevWalk in try-with-resource
  RebaseCommandTest: Open RevWalk in try-with-resource
  PullCommandTest: Open RevWalk in try-with-resource
  BlameGeneratorTest: Create Git instances in try-with-resource
  Remove unnecessary suppression of deprecation warnings in tests
  DiffEntryTest: Open Git and TreeWalk in try-with-resource
  DiffCommandTest: Open Git and RevWalk in try-with-resource
  CommitCommandTest: Open Git and TreeWalk in try-with-resource

Change-Id: Ic886ec9b1a4b3b46f9fa14188b4df832ce36cfa6
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoMerge "Remove unused dependency to commons logging"
Shawn Pearce [Sun, 31 Jan 2016 18:33:31 +0000 (13:33 -0500)]
Merge "Remove unused dependency to commons logging"

8 years agoMerge "Prevent ChainingCredentialsProvider from adding delegated providers twice"
Matthias Sohn [Thu, 28 Jan 2016 23:51:13 +0000 (18:51 -0500)]
Merge "Prevent ChainingCredentialsProvider from adding delegated providers twice"

8 years ago[gitrepo] Support revision in remote tag. 26/65326/4
Yuxuan 'fishy' Wang [Wed, 27 Jan 2016 23:01:47 +0000 (15:01 -0800)]
[gitrepo] Support revision in remote tag.

Repo manifest file allows revision attribute in <remote> tag. This change
teaches JGit to read that information.

Change-Id: I1c878a2505b9d09fa09fbd404a119b71f2fb8fdb
Signed-off-by: Yuxuan 'fishy' Wang <fishywang@google.com>
8 years agoPrevent ChainingCredentialsProvider from adding delegated providers twice 08/65208/1
Rüdiger Herrmann [Tue, 26 Jan 2016 17:55:39 +0000 (18:55 +0100)]
Prevent ChainingCredentialsProvider from adding delegated providers twice

Signed-off-by: Rüdiger Herrmann <ruediger.herrmann@gmx.de>
Change-Id: Icc0907af4fe26877d066db3c813dba37213a3ccc

8 years agoFileTreeIteratorTest: Open Git and RevWalk in try-with-resource 61/65161/1
David Pursehouse [Tue, 26 Jan 2016 08:56:47 +0000 (17:56 +0900)]
FileTreeIteratorTest: Open Git and RevWalk in try-with-resource

Change-Id: I6e68c4b028e0aa01964eace10307372060371df7
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRebaseCommandTest: Open RevWalk in try-with-resource 78/65078/1
David Pursehouse [Mon, 25 Jan 2016 08:05:14 +0000 (17:05 +0900)]
RebaseCommandTest: Open RevWalk in try-with-resource

Change-Id: If7b7a90171d1349d634a84f135471ebac29e3210
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoPullCommandTest: Open RevWalk in try-with-resource 73/65073/1
David Pursehouse [Mon, 25 Jan 2016 06:23:06 +0000 (15:23 +0900)]
PullCommandTest: Open RevWalk in try-with-resource

Change-Id: I676cd7ef4bb29f980a313acd77506dd070e6c98f
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoBlameGeneratorTest: Create Git instances in try-with-resource 72/65072/1
David Pursehouse [Mon, 25 Jan 2016 06:20:24 +0000 (15:20 +0900)]
BlameGeneratorTest: Create Git instances in try-with-resource

Change-Id: I2dc4191603fbd6c3214763b869882c51b0e53284
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRemove unnecessary suppression of deprecation warnings in tests 70/65070/1
David Pursehouse [Mon, 25 Jan 2016 03:00:57 +0000 (12:00 +0900)]
Remove unnecessary suppression of deprecation warnings in tests

Change-Id: I722f8c2e80129e0129349b55a53b29626e2af21c
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoDiffEntryTest: Open Git and TreeWalk in try-with-resource 69/65069/1
David Pursehouse [Mon, 25 Jan 2016 02:55:46 +0000 (11:55 +0900)]
DiffEntryTest: Open Git and TreeWalk in try-with-resource

Change-Id: If4a49268b9b7ec3a44ed1508ed78db365b0c9e5b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoDiffCommandTest: Open Git and RevWalk in try-with-resource 68/65068/1
David Pursehouse [Mon, 25 Jan 2016 02:48:12 +0000 (11:48 +0900)]
DiffCommandTest: Open Git and RevWalk in try-with-resource

Change-Id: I966f7e5053651661abc7de63c968e1f5bf2de464
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoCommitCommandTest: Open Git and TreeWalk in try-with-resource 66/65066/1
David Pursehouse [Mon, 25 Jan 2016 01:41:24 +0000 (10:41 +0900)]
CommitCommandTest: Open Git and TreeWalk in try-with-resource

Change-Id: I65a6fd7028e209c300d992c2756100c09ab4dc19
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRemove unused dependency to commons logging 49/65049/1
Rüdiger Herrmann [Sun, 24 Jan 2016 12:47:31 +0000 (13:47 +0100)]
Remove unused dependency to commons logging

Signed-off-by: Rüdiger Herrmann <ruediger.herrmann@gmx.de>
Change-Id: Ibbca0f7023350a5d424b6a5a84a5d11845a8ded7

8 years agoMerge branch 'stable-4.2' 46/65046/1
Matthias Sohn [Sun, 24 Jan 2016 09:59:14 +0000 (10:59 +0100)]
Merge branch 'stable-4.2'

* stable-4.2:
  ConcurrentRepackTest: Don't use deprecated WindowCache.reconfigure
  ConcurrentRepackTest: Open RevWalk in try-with-resource
  CommitOnlyTest: Open RevWalk in try-with-resource
  UnpackedObjectTest: Create ObjectInserter.Formatter in try-with-resource
  FileRepositoryBuilderTest: Use try-with-resource for auto-closeables
  RepositorySetupWorkDirTest: Fix "resource leak" warnings
  Remove java7 bundle from Maven central scripts
  Prepare 4.2.1-SNAPSHOT builds
  JGit v4.2.0.201601211800-r
  Add progress monitor to Merger
  Fix TransportException when reading bundle
  Fix unused throws CorruptObjectException from addTree

Change-Id: I2325fb995561a6249b7b5e82fa413dfd34ef6007
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoMerge changes Ifdb33501,Idc7b7bbd,Ia3db8696,I4ef82311,I3ad58d4c, ... into stable-4.2
Matthias Sohn [Sun, 24 Jan 2016 01:11:04 +0000 (20:11 -0500)]
Merge changes Ifdb33501,Idc7b7bbd,Ia3db8696,I4ef82311,I3ad58d4c, ... into stable-4.2

* changes:
  ConcurrentRepackTest: Don't use deprecated WindowCache.reconfigure
  ConcurrentRepackTest: Open RevWalk in try-with-resource
  CommitOnlyTest: Open RevWalk in try-with-resource
  UnpackedObjectTest: Create ObjectInserter.Formatter in try-with-resource
  FileRepositoryBuilderTest: Use try-with-resource for auto-closeables
  RepositorySetupWorkDirTest: Fix "resource leak" warnings

8 years agoCompare API against 4.2.0 45/65045/1
Matthias Sohn [Sat, 23 Jan 2016 22:49:30 +0000 (23:49 +0100)]
Compare API against 4.2.0

Change-Id: I08e2cf8f3fbb9e63f4a264daf8d9cc41dde55921
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoFix a @since tag 41/65041/2
Thomas Wolf [Sat, 23 Jan 2016 14:51:47 +0000 (15:51 +0100)]
Fix a @since tag

Ketch didn't make it into 4.2

Change-Id: Iab3ddfb926a2f8d31622e212c845c825369b09d5
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
8 years agoConcurrentRepackTest: Don't use deprecated WindowCache.reconfigure 51/64951/1
David Pursehouse [Fri, 22 Jan 2016 06:03:33 +0000 (15:03 +0900)]
ConcurrentRepackTest: Don't use deprecated WindowCache.reconfigure

Replace with calls to WindowCacheConfig.install() as mentioned in
WindowCache.reconfigure's deprecation notice.

Change-Id: Ifdb33501a2209239029c815b1e4e844ea5b56075
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoConcurrentRepackTest: Open RevWalk in try-with-resource 50/64950/1
David Pursehouse [Fri, 22 Jan 2016 05:59:54 +0000 (14:59 +0900)]
ConcurrentRepackTest: Open RevWalk in try-with-resource

Change-Id: Idc7b7bbdc1df05372b873cbe4c495474f3ffd64b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoCommitOnlyTest: Open RevWalk in try-with-resource 49/64949/1
David Pursehouse [Fri, 22 Jan 2016 05:57:21 +0000 (14:57 +0900)]
CommitOnlyTest: Open RevWalk in try-with-resource

Change-Id: Ia3db8696f66f8d294e1d443fb54e716d26d517b1
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoUnpackedObjectTest: Create ObjectInserter.Formatter in try-with-resource 48/64948/1
David Pursehouse [Fri, 22 Jan 2016 05:51:52 +0000 (14:51 +0900)]
UnpackedObjectTest: Create ObjectInserter.Formatter in try-with-resource

The ObjectInserter.Formatter instance is only used to call idFor.

Factor out a utility method to do that.

Change-Id: I4ef823110c2152ac7905681df3217eb8001f5bd9
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoFileRepositoryBuilderTest: Use try-with-resource for auto-closeables 47/64947/1
David Pursehouse [Fri, 22 Jan 2016 05:30:57 +0000 (14:30 +0900)]
FileRepositoryBuilderTest: Use try-with-resource for auto-closeables

Use try-with-resource to create instances of FileRepository and
FileWriter.

"resource" and "unused" warnings no longer occur, so remove the
suppression annotations.

Change-Id: I3ad58d4cc2d4c019cd8edda7cb401e9d9f3fb790
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRepositorySetupWorkDirTest: Fix "resource leak" warnings 46/64946/1
David Pursehouse [Fri, 22 Jan 2016 05:21:15 +0000 (14:21 +0900)]
RepositorySetupWorkDirTest: Fix "resource leak" warnings

Use FileRepositoryBuilder to create the Repository, except in cases
where the creation was already in a try-block. Convert those to use
a try-with-resource.

Change-Id: I7d7adeee81bda6e80d91a119c7d690de3d00dc2b
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoRemove java7 bundle from Maven central scripts 38/64938/1
Matthias Sohn [Fri, 22 Jan 2016 00:49:22 +0000 (01:49 +0100)]
Remove java7 bundle from Maven central scripts

The bundle org.eclipse.jgit.java7 was deleted in 4.0

Change-Id: I57dbc0b18eaf164c8f53cc2b776ecb80481a993d
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoPrepare 4.2.1-SNAPSHOT builds 37/64937/1
Matthias Sohn [Fri, 22 Jan 2016 00:48:52 +0000 (01:48 +0100)]
Prepare 4.2.1-SNAPSHOT builds

Change-Id: Ic9eac53b10ac97b2038b334d388ae3d21393f993
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoJGit v4.2.0.201601211800-r 33/64933/1 v4.2.0.201601211800-r
Matthias Sohn [Thu, 21 Jan 2016 22:47:12 +0000 (23:47 +0100)]
JGit v4.2.0.201601211800-r

Change-Id: I89f33b0da81ff499315baa5311f95f31724fa510
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoMerge "Remove unused variable from DfsBlockCache"
Terry Parker [Thu, 21 Jan 2016 21:21:14 +0000 (16:21 -0500)]
Merge "Remove unused variable from DfsBlockCache"

8 years agoRemove unused variable from DfsBlockCache 21/64921/2
Terry Parker [Thu, 21 Jan 2016 21:00:45 +0000 (13:00 -0800)]
Remove unused variable from DfsBlockCache

Change-Id: I8ea167e44e9ebcac7ca08920e806d8bcb8188bf0
Signed-off-by: Terry Parker <tparker@google.com>
8 years agoPrepare 4.3.0-SNAPSHOT builds 20/64920/1
Matthias Sohn [Thu, 21 Jan 2016 19:31:10 +0000 (20:31 +0100)]
Prepare 4.3.0-SNAPSHOT builds

Change-Id: Idcf0479529693b023042becd96698f9afd344bd4
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoAdd progress monitor to Merger 01/64901/1
Laurent Delaigue [Wed, 13 Jan 2016 15:56:00 +0000 (16:56 +0100)]
Add progress monitor to Merger

Monitoring progress of merges can be useful for users for large
repositories or complex merge processes that take some time.

This enables setting a monitor. Existing merge implementations in jgit
do not yet report progress if a monitor is set. This will be added in a
later change.

Change-Id: I17b978b3fc91750dd88649638b90a46820a0877c
Signed-off-by: Laurent Delaigue <laurent.delaigue@obeo.fr>
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoFix TransportException when reading bundle 00/64900/1
Chris Gavin [Wed, 6 Jan 2016 15:53:22 +0000 (15:53 +0000)]
Fix TransportException when reading bundle

When reading a bundle file, commit messages who's oneline format is
longer than 982 characters caused JGit to treat subsequent text in
the commit as a SHA, then throw a TransportException because it's
not a valid SHA.

Now the readLine method will read all the way to the end of the
line, not just the first 1024 characters of it.

Change-Id: If15b491aa9a1e4fd9b8bbed2dd9e6be47a64ccb7
Signed-off-by: Chris Gavin <chris@chrisgavin.me>
8 years agoFix unused throws CorruptObjectException from addTree 99/64899/1
Shawn Pearce [Thu, 21 Jan 2016 06:08:23 +0000 (22:08 -0800)]
Fix unused throws CorruptObjectException from addTree

2262a794b48ea removed throws CorruptObjectException, but was not
compiled under Eclipse and did not see errors generated by Eclipse.
Maven build silently ignored the unnecessary code.

Change-Id: I6e9014adcc604588e10e5963d13d0c6ef0e1c617

8 years agoMerge branch 'master' into stable-4.2 98/64898/1
Matthias Sohn [Thu, 21 Jan 2016 16:03:20 +0000 (17:03 +0100)]
Merge branch 'master' into stable-4.2

Change-Id: Ieec4f51aedadf5734ae0e3f4e8713248a3c4fc52
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoMerge branch 'stable-4.2' 72/64872/1
Matthias Sohn [Thu, 21 Jan 2016 13:04:39 +0000 (14:04 +0100)]
Merge branch 'stable-4.2'

* stable-4.2:
  BundleWriterTest: Open RevWalk in try-with-resource
  DiffFormatterTest: Remove accidentally added trailing whitespace
  CherryPickCommandTest: Create Git instances in try-with-resource
  DiffFormatterTest: Create auto-closeable instances in try-with-resource
  ConfigTest: Create Git instance in try-with-resource
  CommitAndLogCommandTest: Use assumeFalse to skip test on Windows
  CommitAndLogCommandTest: Create Git instances in try-with-resource
  AddCommandTest: Create Git instances in try-with-resource
  ArchiveCommandTest: Create Git instances in try-with-resource
  TagCommandTest: Instantiate Git and RevWalk objects in try-with-resource
  BlameCommandTest: Instantiate Git objects in try-with-resource
  SideBandOutputStreamTest: Use try-with-resource
  FileTreeIteratorJava7Test: Create Git instances in try-with-resource

Change-Id: Ib572e98e6117b70442aee9cd7e7b8c3cf65562a7
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoAdd progress monitor to Merger 80/64280/3
Laurent Delaigue [Wed, 13 Jan 2016 15:56:00 +0000 (16:56 +0100)]
Add progress monitor to Merger

Monitoring progress of merges can be useful for users for large
repositories or complex merge processes that take some time.

This enables setting a monitor. Existing merge implementations in jgit
do not yet report progress if a monitor is set. This will be added in a
later change.

Change-Id: I17b978b3fc91750dd88649638b90a46820a0877c
Signed-off-by: Laurent Delaigue <laurent.delaigue@obeo.fr>
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
8 years agoBundleWriterTest: Open RevWalk in try-with-resource 54/64854/1
David Pursehouse [Thu, 21 Jan 2016 10:13:04 +0000 (19:13 +0900)]
BundleWriterTest: Open RevWalk in try-with-resource

Change-Id: Ie25770a73b19d6522bad9fdc0966f48370f96265
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoDiffFormatterTest: Remove accidentally added trailing whitespace 53/64853/1
David Pursehouse [Thu, 21 Jan 2016 10:12:12 +0000 (19:12 +0900)]
DiffFormatterTest: Remove accidentally added trailing whitespace

Change-Id: Ia7a3b05b79c3a5530a4445e6e48ceae445425224
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoCherryPickCommandTest: Create Git instances in try-with-resource 42/64842/1
David Pursehouse [Thu, 21 Jan 2016 09:07:54 +0000 (18:07 +0900)]
CherryPickCommandTest: Create Git instances in try-with-resource

Change-Id: I9d49258bdf12f3221013c37cfb8a21ea27f28860
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoDiffFormatterTest: Create auto-closeable instances in try-with-resource 40/64840/1
David Pursehouse [Thu, 21 Jan 2016 08:00:15 +0000 (17:00 +0900)]
DiffFormatterTest: Create auto-closeable instances in try-with-resource

Git, ByteArrayOutputStream, and DiffFormatter are auto-closeable and
should be managed in try-with-resource.

Change-Id: I83395116acb4b4f7cd4300fd69564355bc07e4bb
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoConfigTest: Create Git instance in try-with-resource 30/64830/1
David Pursehouse [Thu, 21 Jan 2016 06:31:56 +0000 (15:31 +0900)]
ConfigTest: Create Git instance in try-with-resource

Change-Id: Ie65c69e0f1aed95bcdf68ebd68d21b3e2590b41c
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoCommitAndLogCommandTest: Use assumeFalse to skip test on Windows 29/64829/1
David Pursehouse [Thu, 21 Jan 2016 06:30:23 +0000 (15:30 +0900)]
CommitAndLogCommandTest: Use assumeFalse to skip test on Windows

Use JUnit's assumeFalse method to cause the test to skip when
run on Windows.

Change-Id: I3f59440cfe62c37c127e381052b60471fbe8ec5e
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoCommitAndLogCommandTest: Create Git instances in try-with-resource 28/64828/1
David Pursehouse [Thu, 21 Jan 2016 06:25:46 +0000 (15:25 +0900)]
CommitAndLogCommandTest: Create Git instances in try-with-resource

Change-Id: Id06417f1d3914cd3addacdbe9b5801a06cc3955f
Signed-off-by: David Pursehouse <david.pursehouse@sonymobile.com>
8 years agoMerge "Fix unused throws CorruptObjectException from addTree"
Shawn Pearce [Thu, 21 Jan 2016 06:20:42 +0000 (01:20 -0500)]
Merge "Fix unused throws CorruptObjectException from addTree"

8 years agoMerge "Fix TransportException when reading bundle"
Shawn Pearce [Thu, 21 Jan 2016 06:15:10 +0000 (01:15 -0500)]
Merge "Fix TransportException when reading bundle"

8 years agoFix TransportException when reading bundle 57/63657/3
Chris Gavin [Wed, 6 Jan 2016 15:53:22 +0000 (15:53 +0000)]
Fix TransportException when reading bundle

When reading a bundle file, commit messages who's oneline format is
longer than 982 characters caused JGit to treat subsequent text in
the commit as a SHA, then throw a TransportException because it's
not a valid SHA.

Now the readLine method will read all the way to the end of the
line, not just the first 1024 characters of it.

Change-Id: If15b491aa9a1e4fd9b8bbed2dd9e6be47a64ccb7
Signed-off-by: Chris Gavin <chris@chrisgavin.me>
8 years agoFix unused throws CorruptObjectException from addTree 27/64827/1
Shawn Pearce [Thu, 21 Jan 2016 06:08:23 +0000 (22:08 -0800)]
Fix unused throws CorruptObjectException from addTree

2262a794b48ea removed throws CorruptObjectException, but was not
compiled under Eclipse and did not see errors generated by Eclipse.
Maven build silently ignored the unnecessary code.

Change-Id: I6e9014adcc604588e10e5963d13d0c6ef0e1c617