aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/git
Commit message (Collapse)AuthorAgeFilesLines
* More Utils::toSet/toListhjk2019-07-041-3/+3
| | | | | | | ... and unrelated cosmetic changes. Change-Id: I591b17fd5289831e701b683f8fb47816efd1fa67 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Git: Correctly handle aborting pull commandsAndre Hartmann2019-07-022-4/+7
| | | | | | | | | | | | | For example, aborting a "git pull --rebase" command did not work, because the old code tried to run "git pull --abort" instead of "git rebase --abort". As side effect, this patch also enables the Skip commit button in handleMergeConflicts(), that was not shown before. Change-Id: Ifa43a4ba0199c97fdf8a361eb9e0207704d93e26 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Git: Fix popping of branch-stash after checkoutOrgad Shaneh2019-07-015-23/+34
| | | | | | | | | | | | Checking out a branch that has a saved stash, when Pop branch stash is checked, is broken since checkout became asynchronous. We must wait for checkout to complete before popping the branch stash. Change-Id: Ia4d43649e742ced0121ffe106986b4d6ed1e7b38 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* Utils: Rename FileName to FilePathhjk2019-05-2814-40/+40
| | | | | | | | More in line with QFileInfo terminonlogy which appears to be best-of-breed within Qt. Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Replace uses of qVariantFromValue with QVariant::fromValuehjk2019-05-272-2/+2
| | | | | | | | Deprecated in Qt 5.14, alternative has been around since Qt 4 at least. Change-Id: I4e3a53c289088368609e0d0ce2405a832d311308 Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Qt Creator CMake portCristian Adam2019-05-171-0/+41
| | | | | | | | | | | | | | Based on Tobias Hunger's work from a few months ago. The CMake configuration needs libclang and Qt paths specified as CMAKE_PREFIX_PATH. Auto tests are run with "ctest". At the moment the pass rate is 87%. Change-Id: Iba98e39bf22077d52706dce6c85986be67a6eab0 Reviewed-by: Alessandro Portale <alessandro.portale@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* More FileName::appendPath() -> .pathAppended()hjk2019-05-171-3/+2
| | | | | Change-Id: I403d34e4f52f758339c158efc7a11fd329e3e043 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Some more FileName::appendPath() -> pathAppended() changeshjk2019-05-171-3/+2
| | | | | Change-Id: Ie494f7ae8a96d97c9497b3ef38d774d2cf787b7f Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Git: Show at least 5 entries in Branches even if they're oldOrgad Shaneh2019-05-092-12/+63
| | | | | | | Fixes: QTCREATORBUG-22372 Change-Id: Ia4e0477a4e810c3c922cebbad1e44d295abca524 Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* Git: Move parseOutputLine to BranchModel::PrivateOrgad Shaneh2019-05-062-19/+17
| | | | | Change-Id: I885a0f6c6848b63bca0cb3047b28c984087f0bc8 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* Git: Fix CppCheck warnings in BranchModelOrgad Shaneh2019-05-061-3/+4
| | | | | Change-Id: I8c9fa0bff6e33675ad2a72176c4640f4dca3d51b Reviewed-by: André Hartmann <aha_1980@gmx.de>
* Git: Suggest to force-push on non-fast-forward failureOrgad Shaneh2019-05-021-2/+23
| | | | | | | Fixes: QTCREATORBUG-21630 Change-Id: I31564d3909a1e3a3a66daf58323952944d5847f9 Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Git: Give BranchAddDialog for tags a parentAndre Hartmann2019-04-131-1/+1
| | | | | | | Amends 0161729c23 Change-Id: Ie4f5a716e397661d281287a5ac352093cc220035 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Git: Support different reset types in branches viewOrgad Shaneh2019-04-062-6/+9
| | | | | Change-Id: Idce57062cbb92edd4c26647aabef040ec92b9f3c Reviewed-by: André Hartmann <aha_1980@gmx.de>
* Git: Add tags from log windowAndre Hartmann2019-04-035-9/+52
| | | | | | Fixes: QTCREATORBUG-22202 Change-Id: Id6cbaf036d25fe5e9e8fcf2fe4d131649746e128 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* BranchAddDialog: Simplify a bitOrgad Shaneh2019-04-022-11/+8
| | | | | | | | * Remove redundant "Checkbox" translatable string. * Hide "Track remote" checkbox by default. Change-Id: Iec72d035e7b5493b320f8c21dd2f1b90eed0b5e6 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* Merge remote-tracking branch 'origin/4.9'Eike Ziller2019-04-021-1/+1
|\ | | | | | | | | | | | | | | | | Conflicts: qbs/modules/qtc/qtc.qbs qtcreator.pri src/plugins/pythoneditor/pythoneditorplugin.cpp Change-Id: I9a95df5e16b34538539ced7dfc5d326b700794e6
| * Git: Show success message after resetOrgad Shaneh2019-03-281-1/+1
| | | | | | | | | | Change-Id: Icbc731b9b529095e2b8fe0774bfd7eac6455da26 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | GitEditor: Simplify reset menuOrgad Shaneh2019-03-281-28/+21
| | | | | | | | | | Change-Id: Id7f8b9e5aa46530dcb32a4f84bd01d8a8fe2dc5b Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | Git: Support non-recursive grepOrgad Shaneh2019-03-182-3/+15
| | | | | | | | | | Change-Id: Ib38239e28e8b24d993015e5568df02fe2a67f0e8 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | Merge remote-tracking branch 'origin/4.9'Eike Ziller2019-03-051-1/+2
|\| | | | | | | | | | | | | | | | | Conflicts: qbs/modules/qtc/qtc.qbs qtcreator.pri src/tools/clangpchmanagerbackend/source/taskscheduler.h Change-Id: I518adaf647df412887c2a372416634359f09ad2a
| * Git: Suppress command logging for "log" in fixup commit editorOrgad Shaneh2019-03-021-1/+2
| | | | | | | | | | Change-Id: Ib4aee0a38f0e1cf8d2bdf1ae4884f8e75dbb5193 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | Merge remote-tracking branch 'origin/4.9'Orgad Shaneh2019-03-011-1/+4
|\| | | | | | | Change-Id: I801042a53ae4d02d1891ea582ca9ea89b00d3181
| * VCS: Fix display of diff/show commands in progress barOrgad Shaneh2019-02-281-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | In 6ae0e8d2c7f5d1bb3d3240bdfba3cd68eb093252 we added 2 arguments that precede the diff sub-command (-c diff.color=false). When display name is not set, ShellCommand uses the binary followed by the first argument, so it now showed "Git -c" instead of "Git Diff". Change-Id: Ie584837bd87fd529e0cd015025fc3bf1a69d085c Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Xiaofeng Wang <wasphin@gmail.com> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | Squash more deprecation warningshjk2019-02-271-1/+1
| | | | | | | | | | | | | | What a pain. Change-Id: I257e06c647933cc0b752c3c7a83a925b8b627e59 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | Replace static_casts by QOverload where possiblehjk2019-02-263-5/+5
|/ | | | | | | | | Mainly to get rid of the QProcess::finished deprecation warning. Also adjust coding style in the surrounding connects when needed. Change-Id: I12f9b248c7974b892c4a069356e578e80f8c59e9 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Fix some deprecation warnings in basic pluginsFriedemann Kleint2019-02-113-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | Fix warnings apppearing in 5.13, for example: warning: ‘QDir& QDir::operator=(const QString&)’ is deprecated: Use QDir::setPath() instead [-Wdeprecated-declarations] ... warning: ‘static QRgb QColorDialog::getRgba(QRgb, bool*, QWidget*)’ is deprecated: Use getColor() [-Wdeprecated-declarations] warning: ‘Qt::DropAction QDrag::start(Qt::DropActions)’ is deprecated: Use QDrag::exec() instead [-Wdeprecated-declarations] warning: ‘void QProcess::finished(int)’ is deprecated: Use QProcess::finished(int, QProcess::ExitStatus) instead [-Wdeprecated-declarations] ... warning: ‘const QRect QDesktopWidget::availableGeometry(int) const’ is deprecated: Use QGuiApplication::screens() [-Wdeprecated-declarations] ... warning: ‘const QBrush& QPalette::background() const’ is deprecated: Use QPalette::window() instead [-Wdeprecated-declarations] ... warning: ‘const QBrush& QPalette::foreground() const’ is deprecated: Use QPalette::windowText() instead [-Wdeprecated-declarations] ... warning: ‘void QTextOption::setTabStop(qreal)’ is deprecated [-Wdeprecated-declarations] warning: ‘void QList<T>::swap(int, int) [with T = ProjectExplorer::BuildStep*]’ is deprecated: Use QList<T>::swapItemsAt() [-Wdeprecated-declarations] warning: ‘void QProcess::setReadChannelMode(QProcess::ProcessChannelMode)’ is deprecated: Use QProcess::setProcessChannelMode() instead [-Wdeprecated-declarations] ... warning: ‘QString QFileInfo::readLink() const’ is deprecated: Use QFileInfo::symLinkTarget() instead [-Wdeprecated-declarations] Change-Id: I1d893d42d372245892f2de8406f52dbe7bbd552a Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Git: set git config diff.color to falseXiaofeng Wang2019-01-301-0/+2
| | | | | | | | | With diff.color=true, which seems the default or frequently used option, the patch will contains color info. DiffUtils cannot handle this. So, just turn off this option explicitly. Change-Id: I8d8fe972655bea4d638cb34b897346c5b11d5abc Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Fix warning: "Use midRef() instead of mid()"Alessandro Portale2019-01-172-3/+3
| | | | | | | [-Wclazy-qstring-ref] Change-Id: If8a0844b39377feb3772542559655854a92b93cd Reviewed-by: hjk <hjk@qt.io>
* Fix warning: "Missing reference in range-for with non trivial type"Alessandro Portale2019-01-162-2/+2
| | | | | | | [-Wclazy-range-loop] Change-Id: I5dcb263c754d423740e7bce3dcb948d52f2dec67 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Git: Track external changes to HEADOrgad Shaneh2019-01-091-1/+13
| | | | | | Fixes: QTCREATORBUG-21089 Change-Id: Ifcbefd4f57bfdb5c726eced194076503c1dcb497 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* GitEditor: Convert some one-line slots to lambdasAndre Hartmann2018-12-222-29/+13
| | | | | Change-Id: I83326fbbdd5a43bc29924661b51bae57ecbfe0f9 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Merge remote-tracking branch 'origin/4.8'Orgad Shaneh2018-12-034-19/+19
|\ | | | | | | Change-Id: I5b18233936e3b2cd674df92a694ba73b5a3ed752
| * Git: Use ICore::dialogParent as dialog parentOrgad Shaneh2018-11-294-19/+19
| | | | | | | | | | Change-Id: Idc3f2f4d27d3279f76b688fac635e8d38b2705f5 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* | Git: Allow direct checkout in add branch dialogAndre Hartmann2018-11-264-7/+28
| | | | | | | | | | | | | | | | | | | | | | Avoid one modal message box by adding a checkbox in the dialog. In case the user misses to check the box, the branch can still be checked out later with the context menu action "checkout". Change-Id: I51262e694aad9f55511beefa0d8d23ea66429664 Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | Git: add svn dcommitAndre Hartmann2018-11-253-0/+10
| | | | | | | | | | | | | | | | It's the counterpart to git push when working with SVN remotes and git-svn. Change-Id: I02257ea921fdcdedec294b28e8756ed88fb764b3 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* | Merge remote-tracking branch 'origin/4.8'Eike Ziller2018-11-192-4/+7
|\| | | | | | | | | | | | | Conflicts: src/plugins/winrt/winrtdevicefactory.cpp Change-Id: I33b8697e2ebf2bea051d7f1144449e0743ee16a5
| * Git: Fix checking out a branch after adding itOrgad Shaneh2018-11-151-3/+5
| | | | | | | | | | | | | | Fallout from a9ac438ad8e8aa710810133802636aa82f6c821f. Change-Id: I07b36dd1bc5e9fb63f7d4552d9cb6ccd7ea2e22d Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
| * Git: Make commit a bit less synchronousOrgad Shaneh2018-11-141-1/+2
| | | | | | | | | | | | | | | | | | If gc.auto is configured, commit can trigger garbage collection, which takes time. Avoid completely blocking the UI on this case, and at least show the output of the commit command. Change-Id: Id301c878c26599bbc363928a6770c04369a62f2f Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | VCS: Improve dialog on submit promptOrgad Shaneh2018-11-121-5/+1
| | | | | | | | | | | | | | | | | | | | | | The dialog appears when closing the commit dialog without committing, or when "prompt to submit" setting is enabled. Fixes: QTCREATORBUG-18799 Change-Id: I8eb20becbcee7281b9f673a35ec698c6f8e04a40 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Robert Loehning <robert.loehning@qt.io> Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | Git: Block [*_]HEAD for branch nameOrgad Shaneh2018-11-121-0/+1
| | | | | | | | | | | | | | | | | | | | | | Can have false positives, but I think it's better than tracking all of git's internal names. See https://stackoverflow.com/a/17596689/764870 Change-Id: Ifa3d942c4f791e5f8542e0cc174b934f2a95cbcd Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | Git: Show detached HEAD in branches view when applicableOrgad Shaneh2018-11-125-13/+47
| | | | | | | | | | | | Fixes: QTCREATORBUG-21311 Change-Id: Ia4297d23a965d83ea2814bd1e41f35a3017b8e9b Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | Git: Pimpl BranchModelOrgad Shaneh2018-11-112-65/+83
| | | | | | | | | | Change-Id: I18b7fae8b47b449cf1f049a466efb6a1fbb7e522 Reviewed-by: André Hartmann <aha_1980@gmx.de>
* | Git: ModernizeAlessandro Portale2018-11-1010-25/+17
| | | | | | | | | | | | | | | | | | modernize-use-using modernize-use-default-member-init modernize-use-equals-default Change-Id: Iaccd5611cfc2056d357a0545f8522f02d6f8f0ed Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* | VCS: Add reason text when submit validation failsOrgad Shaneh2018-11-102-6/+17
| | | | | | | | | | | | | | | | Change-Id: If4c8d5d1d5dc5386e49b29be59786dc53cfaaaa3 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | Merge remote-tracking branch 'origin/4.8'Eike Ziller2018-11-091-1/+1
|\| | | | | | | | | | | | | Conflicts: tests/unit/unittest/unittest.pro Change-Id: I4f0ab05f96ee60900a3a35fad4c7331238367593
| * Git: Forbid local renaming for date columnAndre Hartmann2018-11-061-1/+1
| | | | | | | | | | | | | | | | | | Renaming the date doesn't make sense. Amends a82dd10518861a869a5a95f6c81868f0785edf86 Change-Id: I2eea83572e3bf69633a6f154a3648b34cf93707f Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* | Merge remote-tracking branch 'origin/4.8'Eike Ziller2018-11-067-25/+62
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/debugger/debuggermainwindow.cpp src/plugins/qbsprojectmanager/qbsbuildstep.cpp src/plugins/winrt/winrtdevicefactory.cpp tests/unit/unittest/gtest-creator-printing.cpp tests/unit/unittest/gtest-creator-printing.h tests/unit/unittest/unittest.pro Change-Id: Ie9b80b87a8a4fa81baf72a2daa7919b21371c15e
| * Git: Enable renaming local branches by direct editingOrgad Shaneh2018-11-044-1/+37
| | | | | | | | | | Change-Id: I7edab94d949a6e48642f280af52fd156c803cafb Reviewed-by: André Hartmann <aha_1980@gmx.de>
| * Git: Remove wrong soft assertionOrgad Shaneh2018-10-281-1/+0
| | | | | | | | | | | | | | There is no restriction of renaming the current branch. Change-Id: I51f3f8d69d1fb108a23a9e9f98364361828531d3 Reviewed-by: André Hartmann <aha_1980@gmx.de>