Skip to main content
AgeCommit message (Collapse)AuthorFilesLines
33 hours[repo view] Let "link with selection" be always enabledHEADmasterThomas Wolf10-153/+116
It's actually a normal state toggling command for which a default handler is fine. It didn't have a default handler because it was badly implemented and assumed that the currently active part was the repositories view. Change the handling of all three toggle commands in the repositories view. Let them only toggle their state, don't make them refresh the view. Make the view listen to state changes and refresh if needed. The content provider doesn't need to listen to changes; it has no way to inform the viewer to refresh. Also remove duplicating the state into local boolean variables; use the state's current value instead. Bug: 537958 Change-Id: I2027a64bd6f4e88439e7975b9d3c3eb3d381efef Signed-off-by: Thomas Wolf <>
2 daysSubmoduleUpdateCommand: close SubmoduleWalk and submodule repositoriesThomas Wolf1-9/+27
Also ensure that EGit operates on the instances from its own RepositoryCache to ensure that the IndexDiffCache gets updated. (Same logic as in the RepositoriesViewContentProvider.) Change-Id: I5db5741b53958199598876793e42389534799cb6 Signed-off-by: Thomas Wolf <>
2 daysClose SubmoduleWalk in RepositoriesViewContentProviderThomas Wolf1-3/+2
Change-Id: If01f7682057397f4829b5ea4760ef2e76f188d40 Signed-off-by: Thomas Wolf <>
3 daysStashing files: Remember selection state for "Include untracked files"Jonas Hungershausen2-0/+13
Bug 540466 Change-Id: Ia33409b16dd6135688dfcd8bde0c9ef11ff1431d Signed-off-by: Jonas Hungershausen <>
6 daysDocument repository view menu insertion pointsMichael Keppler1-7/+7
Trying to get an overview of the available menu items in the repository view context menu, I commented available menu items on the rather generically named "repo-X" insertion points. There are no functional changes. I will close the related bug WONTFIX, since all the mentioned groups have multiple items under certain conditions and can easily be grouped differently. Bug: 538491 Change-Id: Ieff7cc7a3e5929283f52ddb6fe5675ed1918749e Signed-off-by: Michael Keppler <>
6 daysImprove wizard message in Git import wizardMichael Keppler1-1/+1
Since that page only deals with existing repositories, reword the message. Cloning happens on a different path through the wizard. Bug: 537463 Change-Id: I3b2be2f47cc4cddd0447238479931a4a79cbfade Signed-off-by: Michael Keppler <>
6 days[history] Continuous keyboard scrolling over the commit/diff viewerThomas Wolf2-323/+502
Factor out the commit/diff viewer from GitHistoryPage and add key listeners for the arrow keys to provide continuous scrolling over both of the wrapped text viewers. Bug: 463939 Change-Id: I5fefec72674387a8a212c3e5995710ce4d397258 Signed-off-by: Thomas Wolf <>
6 days[regression] Fix resource refreshes after git operationsThomas Wolf3-6/+184
The asynchronous RepositoryChangeScanner must _not_ trigger synchronous refreshes. It uses a non-resource scheduling rule and thus must not perform any workspace operations. Re-introduce the ResourceRefreshJob but let it use the new ResourceRefreshHandler. Re-add merging of events, and re-introduce IProgressMonitor so that the UI bundle can cancel its jobs when being stopped. Bug: 551289 Change-Id: I961ff20355baf7e3d88d2ca222b937f7ffd43fb6 Signed-off-by: Thomas Wolf <>
8 daysRely on synchronous ResourceRefreshHandler to refresh after checkoutMatthias Sohn3-408/+1
- Convert asynchronous ResourceRefreshJob to a synchronous ResourceRefreshHandler. - Move it to EGit core since it does not depend on the UI. - Remove merging of multiple WorkingTreeChanges and progress monitors since that's not necessary when refreshing synchronously. - Unconditionally refresh resources found, even when in projects not shared with EGit. Bug: 551289 Change-Id: I338e4eff366bf2300e347a1da00c2ab0eee6bc14 Signed-off-by: Matthias Sohn <> Signed-off-by: Thomas Wolf <>
8 days[regression][history] Work-around NPE on toggling search barAndrey Loskutov1-0/+16
Make sure the SubContributionItem that contains our contribution also has the proper visibility flag set. Bug: 551067 Change-Id: Ie8aa1742324c2d5cd2002f4ddf012489bd818be5 Signed-off-by: Andrey Loskutov <> Signed-off-by: Thomas Wolf <>
9 daysUse native SWT checkboxes in RefSpecPanelThomas Wolf12-257/+231
Use a special label provider to put SWT.CHECK buttons into a JFace TableViewerColumn. Gives a more native look-and-feel across platforms and themes. Bug: 551719 Change-Id: I32007d3a076e18ee38f8617e3f30322e200d2c8b Signed-off-by: Thomas Wolf <>
9 days[history] Scrolling in the commit/diff viewerThomas Wolf1-0/+56
Scroll the combined commit/diff viewer in the git history view when the caret position changes. Bug: 463939 Change-Id: Ie333b04ccaeb7809ceca732df9a805946ab4a130 Signed-off-by: Thomas Wolf <>
10 daysTrim input when searching for SHA1Michael Keppler1-1/+2
Make history search more fault tolerant by trimming the input, but only when searching for commit ids. Input for other searches is not modified. Bug: 483299 Change-Id: I68b2b86dc2874b5387e07fa3759ff23bd97a4f97 Signed-off-by: Michael Keppler <>
10 daysAvoid NPE after repository deletionMichael Keppler1-0/+4
The selection in the repositories view can be empty after a repository has been deleted. Bug:437573 Change-Id: I5d4797ffa28e7e38a6f09d5bf09180f8404f8de0 Signed-off-by: Michael Keppler <>
11 daysUse Apache HTTP by defaultThomas Wolf3-0/+31
Add a preference with UI to choose between the JDK built-in HTTP handling and Apache HTTP. Set the default to Apache HTTP. In case of trouble the user can switch back to using the Java standard HTTP client. The advantage of the Apache HTTP client is that it allows using Basic authentication when HTTPS connections are to be made over an HTTP proxy. OpenJDK forbids that by default since Java 8u111,[1] and changing the JDK configuration to re-allow it is not obvious at all and cannot be done automatically from within Eclipse. [1] Bug: 549832 Change-Id: I71928b627d3af4dae95bdab63e019c75ab7e6a9e Signed-off-by: Thomas Wolf <>
2019-10-04Preserve executable bit when editing index entriesThomas Wolf1-2/+2
Only change the mode to REGULAR_FILE if the existing entry is not a file. Bug: 551679 Change-Id: I8f6b61bef1c46c9cc343ce1d891b79594d4590a4 Signed-off-by: Thomas Wolf <>
2019-10-02Don't return a path for an IStorage representing an index entryThomas Wolf1-2/+1
Doing so may make some parts of Eclipse conclude the storage really represented an on-disk file and then revert the internal file buffer to that index state, which rolls back all open editors on that file to the index state (and marks them dirty). That's not what we want at all. Occurs for instance with Java files. Adapting to IFile (from commit 0c17469b) to make Eclipse select the right DocumentProvider is fine, but returning a path for the IStorage is not. Bug: 550989 Change-Id: I3f63ad9a4432063d7d1a245c05641fcf12698c2f Signed-off-by: Thomas Wolf <>
2019-10-01Fix git history page double refresh bug on repo switchTim Neumann1-5/+13
When the repository is switched inputSet(RevCommit) is being called, which calls initAndStartRevWalk(...) which in turn sets currentRepo. This causes a repo switched event to be triggered which the ShowFirstParentOnlyPrefAction reacted to with a refresh of the history page and that calls inputSet(RevCommit) again. This commit changes ShowFirstParentOnlyPrefAction to not trigger a refresh on getting a repo changed event. Bug: 551582 Change-Id: I621030d383d48eba7f1ddef27840ce1107e1b7fc Signed-off-by: Tim Neumann <>
2019-10-01Cancel file diff viewer updates earlyMichael Keppler1-1/+8
Put the UI update job of the file diff viewer into the same family as the diff loader job, and cancel all instances of these jobs on history input change. Bug:551578 Change-Id: I0531c6fb6d3eff44c3c8118a52f34a140b4594c8 Signed-off-by: Michael Keppler <>
2019-10-01Simplify collection.toArray() callsMichael Keppler15-29/+19
On recent VMs, collection.toArray(new T[0]) is faster than collection.toArray(new T[collection.size()]). Since it is also more readable, it should now be the preferred way of collection to array conversion. Regex used for search: (?s)\Q.toArray(\E\s*new\s+\w+\Q[\E(?!0) Change-Id: Ifa2f498d97209a01cdb219c79ced20660af91886 Signed-off-by: Michael Keppler <>
2019-10-01Avoid intermediate selection change for Stage/Unstage allMichael Keppler1-17/+17
Stage/Unstage all was previously implemented by programmatically selecting all elements and then calling the stage/unstage selected action. To avoid the intermediate selection update in the control with a flashing effect we instead provide the list of the selected/all elements without modifying the active selection in between. Bug:551539 Change-Id: Ie4c1669fa6e739fbc499d6a5adb19493693bc46c Signed-off-by: Michael Keppler <>
2019-09-30Adapt editor inputs to IFile for merge with index stage 2 as inputThomas Wolf4-75/+166
Otherwise the framework cannot find the correct DocumentProvider, which may cause a PartInitException on opening the merge editor. This uses the same hacks as in LocalNonWorkspaceTypedElement. Bug: 550989 Change-Id: Id024c7f849f4cc6d16e6aa4e845f04f86c9534e5 Signed-off-by: Thomas Wolf <>
2019-09-27CommitFileDiffViewer should use fast hash lookupLars Vogel1-0/+1
Tables perform faster if configured with setUseHashLookup. Only mutable or broken hashcode implementation should use slow tables/trees. Bug: 550247 Change-Id: I8500dc67e3a9c4b0b53c6d944e91f333a7d3c15d Signed-off-by: Lars Vogel <> Signed-off-by: Matthias Sohn <>
2019-09-21Migrate JDT project settings to 2019-09 formatMichael Keppler2-1/+19
There is no change in settings. All the newly added lines are the default values (e.g. iterate all project property pages and apply without changing any value). Be aware that the projects currently do not use identical settings everywhere. That can be cleaned up later. Change-Id: I1d574ca5336abe1a2ee9cfa74a54700f25cb730d Signed-off-by: Michael Keppler <>
2019-09-20[history] Clear selection before clearing commit tableThomas Wolf1-2/+2
Similar to CommitFileDiffViewer. Otherwise the viewer may spend time trying to restore a previously existing selection after the input has changed in StructuredViewer.preservingSelecction(), but when we clear the viewer anyway we know that there won't be anything to restore. Change-Id: I9305d3b03f8e3102f2ecae8d6f729fa1741fce04 Signed-off-by: Thomas Wolf <>
2019-09-20Replace String.equals("") by String.isEmpty()Thomas Wolf7-7/+8
Change-Id: Id48dc5dc3f40b93ef3b597e6adc40c47c996cfd4 Signed-off-by: Thomas Wolf <>
2019-09-17Use HashMap.computeIfAbsent()Thomas Wolf5-41/+14
Simplifies code a little, and may be sometimes be a tiny bit faster since it hashes and finds an entry only once. In IndexDiffCache, it also enables us to get rid of explicit synchronized blocks and use a ConcurrentHashMap instead. Change-Id: Ibf99dec71c62ee682fff9fdad7f06f7232db37b2 Signed-off-by: Thomas Wolf <>
2019-09-17Match full branch names in branch selection dialogMichael Keppler1-1/+21
With hierarchical branch layout enabled, the filter in the branch selection dialog doesn't match when entering something like "origin/master" due to each node only having one part of the ref name as label. Bug:550886 Change-Id: I49153b0aa06c7c7af6171494fb5cef608f5bb108 Signed-off-by: Michael Keppler <>
2019-09-17Improve performance of command parameter completionMichael Keppler1-9/+9
* check for accessible first before trying to get the team provider * use parallel streams Bug:551149 Change-Id: Id0def461db3d4f96732f5d0ff129db111935ec8f Signed-off-by: Michael Keppler <>
2019-09-17New filter icons for Eclipse 4.14Thomas Wolf11-7/+17
Use the new filter icon from the IDE on platforms that do have it. On older platforms keep using the old icon. Bug: 550597 Change-Id: Ie41327e7aaf0a660753092ed22540e935a6851e1 Signed-off-by: Thomas Wolf <>
2019-09-15Re-layout line number ruler in unified diff viewerThomas Wolf1-0/+9
The old-new line number ruler in the diff viewer in the commit editor did not always properly adapt its size when the size of the text editor changed. Visible for instance after maximizing a diff viewer such that there is no horizontal scroll bar anymore, then resetting to its original size. Line numbers would suddenly appear at the very bottom, next to the (now visible again) horizontal scroll bar. Force a re-layout when the size of the editor changes. This fix is crucial for , which otherwise may run into exceptions trying to draw images with a negative height. Change-Id: I8a750f57ab9804c932a92b40c0c92988229c5032 Signed-off-by: Thomas Wolf <>
2019-09-12Use HTTPS linksThomas Wolf1-2/+2
Update all target platforms, about.html, feature.xml, and maven repositories to use HTTPS links. Change-Id: I73e3bb091b723481d323a1ea47b5b153617ab583 Signed-off-by: Thomas Wolf <>
2019-09-11Merge branch 'stable-5.5'Matthias Sohn1-0/+49
* stable-5.5: Prepare 5.5.1-SNAPSHOT builds EGit v5.5.0.201909110433-r Update documentation for 5.5.0 Fix saving in the merge editor Change-Id: I08fd5c203faec328191fb733c2222081cc44e5f0 Signed-off-by: Matthias Sohn <>
2019-09-11Prepare 5.5.1-SNAPSHOT buildsMatthias Sohn2-91/+91
Change-Id: I9ce93a113e74a29385666564d9b464de6a4b9222 Signed-off-by: Matthias Sohn <>
2019-09-11EGit v5.5.0.201909110433-rv5.5.0.201909110433-rMatthias Sohn2-2/+2
Change-Id: Ia370d4d63d8d745e64aff6314e09fe5a33f62790 Signed-off-by: Matthias Sohn <>
2019-09-09Fix saving in the merge editorThomas Wolf1-0/+49
Somehow the local file elements in the GitMergeEditorInput got flushed only, but not saved. Add a listener that saves the item when flushed. Bug: 550870 Change-Id: Ifcb22182baa85007de20f3e7cf0d375959c79593 Signed-off-by: Thomas Wolf <>
2019-09-08Remove unused codeMichael Keppler1-7/+0
The only caller of that method was removed 8 years ago. Change-Id: I07e140a0418fcad273c98237f64407fd2da38446
2019-09-08Fix typos in commentsMichael Keppler2-2/+2
No functional changes. Change-Id: I04b8fc9b9ac03ab2466d034b5963e19a24bf0b25 Signed-off-by: Michael Keppler <>
2019-09-08Fix visibility of Team->Advanced->Create TagThomas Wolf1-1/+3
This menu contribution needs the visibleWhen clause that got replaced in commit 97c96f88, otherwise it will be visible in the context menu of the history view. Bug: 550820 Change-Id: I7b3dd816767bfcf10b5a3b89f4de9257a95e6c5e Signed-off-by: Thomas Wolf <>
2019-09-08Use an OSGi declarative service instead of IStartupThomas Wolf7-11/+36
Replace the IStartup and org.eclipse.ui.startup extension point by a declarative OSGi service component listening on UIEvents.UILifeCycle.APP_STARTUP_COMPLETE. Bug: 550742 Change-Id: I04ee521810f0aa05f64f24460f07ea5060505dfc Signed-off-by: Thomas Wolf <> Signed-off-by: Michael Keppler <>
2019-09-05Eliminate exactRef(HEAD) on the UI thread in the history tableThomas Wolf5-26/+65
CommitGraphTable.doPaint() called input.getHead() every time. This is a fairly expensive file access occurring on the UI thread for every row that is painted. At least, it will check whether HEAD and the ref it may point to have been modified. Eliminate these calls from the UI thread completely by doing it once in the SWTWalk, which runs in the background. Once determined, the head Ref can be obtained through the SWTCommit. The CommitGraphTable (or rather, the SWTPlotRenderer) uses the head Ref *only* to bolden the branch that is HEAD. Bug: 544600 Change-Id: Iea994a0f426a574c26501f4151bc568461dc8aaf Signed-off-by: Thomas Wolf <>
2019-09-05Cache more repository state for re-use in the UI threadThomas Wolf26-218/+597
Many EGit commands depend on some repository state determining their enablement. Eclipse re-evaluates activation/enablement expressions or handlers' isEnabled() method very frequently. For globally available handlers, on every selection change; for others for instance when they are included in some (context) menu. JGit operations to determine repository state access the file system (typically config files, or the packed_refs file, or loose refs), and check every time whether the file has been changed since the last access. In the case of a repository config file, this check is even done for the user and system config files, too. If JGit determines that a file has been changed it reloads it, perhaps even multiple times depending on the file timestamp resolution. Thus accessing the repository config file or determining the currently checked out branch are expensive file system operations. Handler enablements are evaluated on the UI thread, so EGit did *a lot* of expensive file system accesses on the UI thread, which slows down Eclipse startup and context menus in particular. Introduce a cache for the most important values of a repository that are used in property testers and in handler activation and enablement code. The cache is cleared whenever the workbench selection or the "menu selection" changes to avoid serving stale values. When Eclipse then re-evaluates enablements, only the first expressions will actually access the file system, while all later re-evaluations due to a selection change will use the cached values. Caching values until the next selection change is a valid strategy. When a series of enablements is re-computed, these re-computations are all based on the same selection, thus using the repository state as it was at the beginning is fine. This greatly reduces the number of times EGit accesses the file system on the UI thread and generally makes the EGit UI *much* snappier. This cache should be used only for evaluations that are known to happen synchronously in the UI thread in response to a selection change. This includes property testers and isEnabled() on handlers. Bug: 544600 Change-Id: Idd369b50d8b4bd6dd68b30d640bbc13f5a5976c5 Signed-off-by: Thomas Wolf <>
2019-09-05Merge branch 'stable-5.5'Matthias Sohn1-11/+38
* stable-5.5: Update Orbit to R20190827152740 for 2019-09 Prepare 5.5.0-SNAPSHOT builds EGit v5.5.0.201909041048-rc1 Use https in update site URLs Ensure staging view widgets get re-enabled Change-Id: Ia1b7e409556bafe0897e768ec70e633964d3335c Signed-off-by: Matthias Sohn <>
2019-09-04Prepare 5.5.0-SNAPSHOT buildsMatthias Sohn2-2/+2
Change-Id: I3527681cf219e8e0a358986398891a3a1fe8b303 Signed-off-by: Matthias Sohn <>
2019-09-04EGit v5.5.0.201909041048-rc1v5.5.0.201909041048-rc1Matthias Sohn2-2/+2
Change-Id: I2f07b70159f12597aea840beadfeeb631b77ad19 Signed-off-by: Matthias Sohn <>
2019-08-29Ensure staging view widgets get re-enabledThomas Wolf1-11/+38
Make sure the staging view widgets, which get disabled before a commit, get re-enabled if something goes wrong and a RuntimeException is thrown. See bug 550336. As far as I see the only possibility where the widgets could remain disabled is if the scheduled job never terminates. If a RuntimeException does occur log and show the error to the user. Previously it was apparently only logged. Bug: 550513 Change-Id: I74b2268666a2e441a76a48d462e25f119380760b Signed-off-by: Thomas Wolf <>
2019-08-29Prepare 5.6.0-SNAPSHOT buildsMatthias Sohn2-91/+91
Change-Id: I617ef95d0f31df937987d1d4046b0f10db05cf47 Signed-off-by: Matthias Sohn <>
2019-08-28Prepare 5.5.0-SNAPSHOT buildsMatthias Sohn2-2/+2
Change-Id: I8f1969e5bcfae5a148505a0fe291372862ce99e4 Signed-off-by: Matthias Sohn <>
2019-08-28EGit v5.5.0.201908280940-m3v5.5.0.201908280940-m3Matthias Sohn2-2/+2
Change-Id: I434ea0ec51c0209b908227ba4ae7f0b7514f2791 Signed-off-by: Matthias Sohn <>
2019-08-27History view: shorten view toolbarThomas Wolf6-67/+179
Combine the four filter buttons into one single button with a drop-down menu. Selecting the button itself cycles though the filters. Use the new FilterAction also in the view menu; to be able to do so implement ToolBarMenuAction.getMenu(Menu) and rename the class to DropDownMenuAction. Also, as long as one only updates the image of an action it isn't necessary to update the whole toolbar. The framework listens for such changes and updates the corresponding ToolItem or Menu entry already. Change-Id: If7fb1e3199cd1721a4455bac10925fc2922c5ba8 Signed-off-by: Thomas Wolf <>

Back to the top