summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add type argumente to some raw reclarationRobin Rosenberg2012-12-2713-33/+51
| | | | Change-Id: Ief195fb5c55f75172f0428fdac8c8874292ae566
* Do not perform character translation on copies in patchesRobin Rosenberg2012-12-271-3/+8
| | | | | | | Translation is unnecessary and risks damaging the file. Also ensure that we close the file if an I/O error occurs. Change-Id: Ieae6eb941fdeaa61f2611f4cd14dd39117aa12f9
* Mark non-externalizable strings as suchRobin Rosenberg2012-12-27259-1329/+1404
| | | | | | | | | | A few classes such as Constanrs are marked with @SuppressWarnings, as are toString() methods with many liternal, but otherwise $NLS-n$ is used for string containing text that should not be translated. A few literals may fall into the gray zone, but mostly I've tried to only tag the obvious ones. Change-Id: I22e50a77e2bf9e0b842a66bdf674e8fa1692f590
* Add org.eclipse.jgit.pgm.Reset to commands catalogTomasz Zarna2012-12-221-0/+1
| | | | | Change-Id: I7acfd051a07be889b27cfcfc1f396d86a9f86ab2 Signed-off-by: Tomasz Zarna <tzarna@gmail.com>
* Prepare 2.3.0 buildsMatthias Sohn2012-12-2143-238/+238
| | | | | Change-Id: I0ca539e8cfe444f96c64dc56d1f0ef33b66e0cff Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Merge branch 'stable-2.2'Matthias Sohn2012-12-211-1/+1
|\ | | | | | | | | | | | | | | * stable-2.2: Prepare post 2.2.0.201212191850-r builds JGit v2.2.0.201212191850-r Change-Id: Iebe7c45eacb8abee21d1900e27143ccaa2724e28 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * Merge remote-tracking branch 'gerrit/stable-2.2'Robin Rosenberg2012-12-1615-13/+498
| |\ | | | | | | | | | | | | | | | | | | | | | | | | * gerrit/stable-2.2: Ensure that jgit p2 repository is self-contained Fix hidden field warning Fix empty control block warnings Change-Id: Ifa0751be7db9401081a1a5c28a0102a2d0c692f9
| * \ Merge branch 'stable-2.2'Robin Rosenberg2012-12-154-6/+150
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | * stable-2.2: DirCacheIterator: Fix reset() and back() Cleanup unused import and Java 6 syntax in Archive Change-Id: Icc59b28a4066c4781ea8d6270dfe20eb63b4185e
| * | | Disable response compression on /git-receive-pack URLsShawn Pearce2012-12-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Compressing the response with gzip causes the stream to delay flushing until gzip has seen the entire response message, or buffers fill up and the compressed data has to be sent. This hides the resolving progress monitor from the client, as well as any other progress messages the server might be trying to send. Disable compression in receive, matching what /git-upload-pack has. Change-Id: Ic8d8abe1f43c3f540d1ee7c43a8947a555307d94
* | | | Prepare post 2.2.0.201212191850-r buildsstable-2.2Matthias Sohn2012-12-2143-53/+53
| | | | | | | | | | | | | | | | Change-Id: I1a0fe51c71551fcfc98f5dd435eb283fd661b77a Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | | | JGit v2.2.0.201212191850-rv2.2.0.201212191850-rMatthias Sohn2012-12-2043-53/+53
| |_|/ |/| | | | | | | | | | | Change-Id: Idc49f17d03886b6a1e61a94ff81e32625c8675d9 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | | Ensure that jgit p2 repository is self-containedMatthias Sohn2012-12-1614-3/+487
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a new feature for the 3rd party dependencies jgit needs and include this in org.eclipse.jgit.feature. This ensures that the jgit p2 repository is self-contained and downstream consumers don't need to find the dependencies elsewhere. We don't add the jetty dependencies needed to install the test feature org.eclipse.jgit.junit since this is only used by egit tests. Change-Id: I60425c746cd50f1875ef8597a8bbefb598b8c982 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | | Merge "Fix hidden field warning" into stable-2.2Robin Rosenberg2012-12-151-3/+3
|\ \ \
| * | | Fix hidden field warningMatthias Sohn2012-12-121-3/+3
| | | | | | | | | | | | | | | | Change-Id: Ic52527c32f8167db3c7bb7fa0297c86fee21da27 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | | | Merge "Fix empty control block warnings" into stable-2.2Robin Rosenberg2012-12-151-7/+8
|\| | | | |_|/ |/| |
| * | Fix empty control block warningsMatthias Sohn2012-12-121-7/+8
| | | | | | | | | | | | Change-Id: I7c546fa89f5e1933cff6648b2e03e07db61273e8 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | | DirCacheIterator: Fix reset() and back()Robin Rosenberg2012-12-153-1/+150
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | reset() was broken and probably only worked when the position was at the beginning. More serious was that back() sometimes descended into the tree rather than skipping backward at the same level. Sometimes this would result in false conflicts, but one could suspect silent errors too. back() is called by the NamingConflictTreeWalk when looking for directory/file conflicts. Also added toString to DirCacheTree to simplify debugging. Bug: 396127 Change-Id: Iaa1b4e20e623d84c2e5ac26748f42e991080dbcd
* / Cleanup unused import and Java 6 syntax in ArchiveRobin Rosenberg2012-12-121-5/+0
|/ | | | | | | @Override for implementation of interface is Java 6. JGit's execution environment is still Java 5. Change-Id: I48d10b3bf81a60938da86e026053b2f3d5e24ad3 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Merge "archive: Add tar support"Shawn Pearce2012-12-054-9/+199
|\
| * archive: Add tar supportJonathan Nieder2012-12-044-9/+199
| | | | | | | | | | | | | | | | Unlike ZIP files, tar files do not treat symlinks as ordinary files with a different mode, so tar support involves a little more code than would be ideal. Change-Id: Ica2568f4a0e443bf4b955ef0c029bc8eec62d369
* | Merge "archive: Add --format option that switches between formats"Shawn Pearce2012-12-054-19/+66
|\|
| * archive: Add --format option that switches between formatsJonathan Nieder2012-12-044-19/+66
| | | | | | | | | | | | | | Prepare for .tar support. Change-Id: Ieb07702da1a54b41ae764fbb425f70826907b593 Improved-by: Shawn O. Pearce <spearce@spearce.org>
* | Merge "archive: Record executable and symlink bits"Shawn Pearce2012-12-052-4/+84
|\|
| * archive: Record executable and symlink bitsJonathan Nieder2012-12-042-4/+84
| | | | | | | | | | | | | | | | | | | | | | Setting the mode for a zip entry is now as simple as "entry.setUnixMode(mode)", so do that. The test checks using the system's "zipinfo" command (from InfoZIP) that the mode has been recorded correctly on systems that happen to have a "zipinfo" command, using org.junit.Assume to distinguish them. Change-Id: I4236c102fd76f18d01b2dc926eeb9b9fa11a61b7
* | [findBugs] Don't pass null for non-null parameter in RebaseCommandMatthias Sohn2012-12-053-1/+7
|/ | | | Change-Id: Iee4d50aa9c6b75f9906d2c51a940ddc90a944192
* Merge "[RFC] archive: Switch to commons-compress as ZIP archiver"Shawn Pearce2012-12-044-6/+20
|\
| * [RFC] archive: Switch to commons-compress as ZIP archiverJonathan Nieder2012-12-034-6/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Apache Commons Compress library provides a similar interface to java.util.zip with some features not found in java.util.zip, including support for inclusion of metadata (file mode and symlink targets) and support for multiple file formats (zip, .tar.xz, etc). Use it, in preparation for making use of these features. No functional change intended yet. A previous version of this patch used plexus-archiver. That is a heavier-weight dependency and offers a less convenient interface. Thanks to James Moger and Chris Aniszczyk for advice. Change-Id: Id01146950bb9c18dae0169311e3cde2c3bfa675e
* | Merge "Commit message may not necessarily be in UTF-8"Shawn Pearce2012-12-041-2/+2
|\ \
| * | Commit message may not necessarily be in UTF-8Robin Rosenberg2012-11-271-2/+2
| | | | | | | | | | | | | | | | | | | | | Trying different encoding makes presentation nicer to user. Change-Id: I2d2c2a95d0b5cd709855d7a67cbc247478434d2f
* | | Fix DeltaWindow.clear() to release loaded buffer bytes.Colby Ranger2012-12-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | It is possible for the buffer to be set but not the index. It ocurrs when an exception occurs during creating an index, but after the buffer is loaded. Furthermore, the cleared DeltaWindowEntry should have been ent and not res. Change-Id: I2e0d79540316635bf7aa43efd225e4eb38230844
* | | Enable reuse of FileTreeIterator and FileEntry for non subclassesRobin Stocker2012-12-031-2/+11
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | For EGit change I2c41d86b8b74c2a334433de1bbfed5b36af872bf, ContainerTreeIterator also needs to create entries for File objects in case of filtered resources. Instead of reimplementing FileEntry there, make the constructor public so that it can be reused. Also allow to pass a WorkingTreeIterator instead of a FileTreeIterator in FileTreeIterator's constructor, which is enough and allows to pass other subclasses. Bug: 358901 Change-Id: Ie0f9c9434ef7d73a8d73d4fe46db4147ded1d267 Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* | Merge "Support --cached in RmCommand"Chris Aniszczyk2012-12-032-13/+64
|\ \
| * | Support --cached in RmCommandRobin Stocker2012-12-032-13/+64
| | | | | | | | | | | | | | | | | | | | | | | | Also extend documentation and add examples. Bug: 395599 Change-Id: Id1ddbc9da787472f82e58834092bc073224b262b Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* | | Add basic "jgit add" testsJonathan Nieder2012-11-292-0/+116
|/ / | | | | | | | | Change-Id: I056c2556c7db98bf57e2527dec11af7c3daf472a Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* | add: Fix bad metaVar reference in <filepattern> helpJonathan Nieder2012-11-282-1/+2
| | | | | | | | | | | | | | | | | | | | Without this patch, "jgit add --help" throws two exceptions (NoSuchFieldException: metavar_filepattern; MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key metavar_filepattern) instead of printing a usage message, due to a small typo and a missing declaration. Change-Id: I4b848b3a8c7b1a49d8b9582809375daa4aca6b50
* | Merge "Do not warn about non-translated strings in the ant library"Chris Aniszczyk2012-11-251-1/+1
|\ \
| * | Do not warn about non-translated strings in the ant libraryRobin Rosenberg2012-11-251-1/+1
| | | | | | | | | | | | | | | | | | | | | Ant tasks are generally not translated, hence don't warn about untranslated strings Change-Id: I60920ccdaf3c0139979bb4ef19eb42036bb7e07f
* | | Merge "Do not warn about non-translated strings in the iplog generator"Chris Aniszczyk2012-11-251-1/+1
|\| |
| * | Do not warn about non-translated strings in the iplog generatorRobin Rosenberg2012-11-251-1/+1
| | | | | | | | | | | | | | | | | | | | | This module is used by very few people so translation is not a priority and hence we need no warnings about untranslated strings. Change-Id: I11be2e9903583d1a3dade7bf3d5eb77a30152b7c
* | | Merge "Do not warn about non-translated strings in the http library"Chris Aniszczyk2012-11-251-1/+1
|\| | | |/ |/|
| * Do not warn about non-translated strings in the http libraryRobin Rosenberg2012-11-251-1/+1
| | | | | | | | | | | | The strings here are for machine-to-machine communications. Change-Id: Ia0d19fce3d9843d18d329d9bc5b10d62c4125db8
* | Add a case statement for fast-forward mergeRobin Rosenberg2012-11-251-0/+1
|/ | | | | | | This case was ommitted. Treat the same as a non-fastworwad merge. Change-Id: Ia81e2430dfe04c3ce9b6e2f8fb4b6c646293a174
* RevWalk support for shallow clonesMarc Strapetz2012-11-2114-28/+318
| | | | | | | | | | | | StartGenerator now processes .git/shallow to have the RevWalk stop for shallow commits. See RevWalkShallowTest for tests. Bug: 394543 CQ: 6908 Change-Id: Ia5af1dab3fe9c7888f44eeecab1e1bcf2e8e48fe Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Add support for rebase interactive 'edit' commandDariusz Luksza2012-11-192-7/+72
| | | | | | | | | | The 'edit' command allows you to change arbitrary commit content and the message of any commit in the repository. Bug: 394577 Change-Id: I43a44782cdb10b29f13784fa75ab37fe5d4da01b Signed-off-by: Dariusz Luksza <dariusz@luksza.org> Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Add support for rebase interactive 'reword' commandDariusz Luksza2012-11-192-7/+187
| | | | | | | | | | 'reword' command is used to change commit message of any commit in git history. Bug: 394575 Change-Id: Ic974e76dfd923fd6f0cb8f07d1a6fbecd9abbf31 Signed-off-by: Dariusz Luksza <dariusz@luksza.org> Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Add GarbageCollectCommand to porcelain APIMatthias Sohn2012-11-185-0/+253
| | | | | | | Bug: 394544 Change-Id: I73faa55d860db64efc3412fee27386df47552a75 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Have git-ls tree to accept path args like git-ls-treeKetan Padegaonkar2012-11-181-2/+14
| | | | | | | | | | Usage is: jgit ls-tree [-r|--recursive] <tree-ish> [-- paths...] Change-Id: I2e1c9c3cc8cddfa12ca4bfb9afc4df0492a9fce1 Signed-off-by: Robin Rosenberg <robin.rosenberg@dewire.com> Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Add config constant for "mergeoptions"Tomasz Zarna2012-11-181-0/+3
| | | | | | Bug: 336933 Change-Id: Idcc0fbc8a8143dd665e80e4d6f4a4adaeae287db Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Add "jgit archive" tool that writes a tree as a ZIP fileJonathan Nieder2012-11-165-0/+285
| | | | | | | | | | | | | | | | | | | | | | | C Git's "git archive" command represents a tree object using a standard archival format like tar, zip, or tgz, ready for consumption by other, git-unaware users or tools. Add a bare-bones analagous "jgit archive" command to show what is possible, supporting only ZIP format for now. It uses java.util.zip which is not aware of the InfoZIP extensions for representing symlinks and file permissions, so symlinks, executable files, and submodule entries are represented as plain text files. Making this functionality available from the library, improving handling of special entries, and support for other output formats are left for later patches. Ultimately the intent is to offer a TreeArchiveStream class for use by web frontends like Gitiles to offer "download as zip/tgz/txz" links and use by, for example, code search tools to get easy access to the content of git tree objects. Test with "jgit archive my-favorite-tree >out.zip". Change-Id: Ib590f173ceff3df4b58493cecccd6b9a1b355e3d
* Allow commandline tests to use raw outputJonathan Nieder2012-11-161-4/+11
| | | | | | | | | | | | | | | | | | | | | Introduce a new CLIGitCommand.rawExecute() helper that behaves just like execute() except that instead of processing its output it returns it raw. So now you can do final byte[] expect = { 0, 1, 2, 3 }; final byte[] actual = CLIGitCommand.rawExecute( "git show HEAD:goo.raw", db); assertArrayEquals(expect, actual); to test the output from "git show HEAD:goo.raw" without being distracted by encoding issues. Noticed while writing tests for a new "jgit archive" command that writes its output in ZIP format. Change-Id: I2fe6020a537975d0ccf414b7125d85d6cd86898c