Commit Graph

895 Commits

Author SHA1 Message Date
Orgad Shaneh
a6626b49c4 Git: Reorder reset types
Hard is now the default (as it is in 2.7), and the types are
properly ordered

Task-number: QTCREATORBUG-9733
Change-Id: I54fb22543bf31f43381e57fb0acf4aeb15e8a293
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Robert Loehning <robert.loehning@digia.com>
2013-07-06 20:18:52 +02:00
Orgad Shaneh
3cefd0288e Git: Remove wrong assertions
Changed in 89523c14

Change-Id: I872c37633a877e982046b2a44266159d86defbde
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
2013-07-06 20:18:14 +02:00
Orgad Shaneh
2103a4a96c Git: Clear branches model when repository becomes empty
Change-Id: I78932b342de5e1b29c75ed921d4d6afddf4d51da
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2013-07-04 17:59:49 +02:00
Orgad Shaneh
a26c884b70 Git: Preserve current selection on log change refresh
Change-Id: Ic6be652a1d5cca87ae5effdcb3cb5df7b1b73c2c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
2013-07-04 16:57:43 +02:00
Orgad Shaneh
be5133cf72 Git: Update branches dialog when repository is changed
and on fetch

Task-number: QTCREATORBUG-9667
Change-Id: Id2e5080502bbc28d5f7900dd0433e468dda56c82
Reviewed-by: Robert Loehning <robert.loehning@digia.com>
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
2013-07-04 15:26:39 +02:00
Orgad Shaneh
00337585ab Git: Add some null protections
Change-Id: Ia28c70690c6f79499fb8075935ec123b763bcc01
Reviewed-by: Jarek Kobus <jaroslaw.kobus@digia.com>
2013-07-02 08:52:30 +02:00
Orgad Shaneh
5f131da166 DiffEditor: Show tags and branches in Show pane
Change-Id: I39be7c3fb9b57b133c4da3639813527aa280ae33
Reviewed-by: Jarek Kobus <jaroslaw.kobus@digia.com>
2013-07-01 15:50:12 +02:00
Orgad Shaneh
32217a0c3c Git: Move static strings out of GitClient class
They're only used in gitclient.cpp, define them there

Change-Id: I601f23a6f2a8e533127d2ed068526815e1b9717d
Reviewed-by: hjk <hjk121@nokiamail.com>
2013-07-01 15:42:16 +02:00
Orgad Shaneh
f621ee5bc4 Git: Diff current file against index
Task-number: QTCREATORBUG-9663

Change-Id: I18b4ec5577bf0114075141583c938eaa02d5eded
Reviewed-by: Jarek Kobus <jaroslaw.kobus@digia.com>
2013-07-01 11:22:49 +02:00
Orgad Shaneh
893b1e9a16 Git: Support commit.template under ~
Task-number: QTCREATORBUG-9530

Change-Id: I21ee4202aa750a9d4d89f05d51af7c63489eb6c3
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2013-07-01 11:21:54 +02:00
Orgad Shaneh
62554e7647 Git: Add a soft assertion
If directory is empty, buttons remains NULL, which leads to a crash

To reproduce, open Branches dialog then close all editors
and projects and click Log for a branch

Change-Id: Icf06b76c58585c0dd6062017e94e07dad016c275
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
2013-07-01 10:35:02 +02:00
Leena Miettinen
41411165ba Doc: use standard wording in \brief commands
QDoc does some magic with the \class and \namespaces
and \brief commands, so the following wording must be used:
"The xxx class yyy ..."

Change-Id: Id231f30e8464898b776888d5423523de404aae34
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2013-06-20 11:22:47 +02:00
Orgad Shaneh
57a6f04ce6 Git: Prevent tracking tags
Change-Id: Iea935aa226b70de936653b7637b4b9bb5e9c64cf
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-19 22:07:06 +02:00
Orgad Shaneh
11e7c706be Git: Make tree layout consistent on add branch
Change-Id: I3b49d76ef0e3da9ab60d6859a8b8e18092794bbb
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-19 22:06:22 +02:00
Eike Ziller
f7349e49df Fix build
The (un)expectDirectoryChange API addition has been reverted

Change-Id: I4736f51a77eb2f63b3e4a7b44426ad15a06624c7
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2013-06-19 11:49:52 +02:00
jkobus
f5a2c1469a Add a DiffShowEditor showing an additional info
Task-number: QTCREATORBUG-9489

Change-Id: I3ae2e59ccaf397f4236505f21e027a42e2798784
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2013-06-19 09:11:42 +02:00
Petar Perisin
159a7d61dd Git - stash scope guard in submoduleUpdate
Change-Id: I888d4013e88fdc6977f29ef3e27d243e55a1f1a7
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2013-06-17 22:22:31 +02:00
Orgad Shaneh
8ce981e673 Git: Fix false positive for tracking branch
Change-Id: Ib08b5b276708a5951ed421e674a10d4763032502
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-17 15:51:50 +02:00
Orgad Shaneh
744d5d51ab Git: Display tracking branch for newly created branches
+ Get rid of a workaround done for retrieving sha

Change-Id: I4b7a6c6d9e9be5766f4fc540dc8b15037eb7948c
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-17 13:51:27 +02:00
Orgad Shaneh
3591c1df57 Git: Disable rebase and fixup when there's a command in progress
Change-Id: Ifa2f781cb1f31afaf7b0af4e4a0dd08fb58296d3
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-17 11:21:19 +02:00
Orgad Shaneh
1686e314bd Git: Use log instead of show to display commit without diff
Change-Id: I12ff53e3375470704fb6aafa6ec0a3eaadd9aadb
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-17 11:20:43 +02:00
Orgad Shaneh
096daac0bd Git: Execute rebase asynchronously
Rebase --continue might request an editor, which hangs if run
synchronously

Change-Id: I28127884408f6f8fbd351bb1024dc8d3c2b339b8
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-17 10:56:05 +02:00
Orgad Shaneh
fc2a5d7f50 VCS: Preserve uncheckable files on submit editor refresh
Change-Id: I652b5a96c994a13f8d0c02d850b15c5846d56e64
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-17 10:54:51 +02:00
Orgad Shaneh
9f72e43fb1 Git: Refresh log entries on fixup commit
Change-Id: Icd14c8916dc006874b77aa922b3f1c6746e0549c
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-17 10:53:14 +02:00
Orgad Shaneh
7ff6dcabd1 Git: Handle merge conflicts on stash pop
Change-Id: I41a9173be2feae4ab529fd9b3f2e1e7cc5ae92ff
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-17 10:44:27 +02:00
Orgad Shaneh
e9443ff51f Git: Show tracking branch on Branches dialog
Simplify branch model parsing a bit

Change-Id: Id9e41c6c2769397d6eee3ab74de4afbb94111e25
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
2013-06-14 13:50:50 +02:00
Orgad Shaneh
89523c1467 Git: Allow merge and rebase for detached HEAD
Change-Id: Ia00c061b1f4a705cf815052921e6f6cf43d0867d
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-13 17:20:15 +02:00
Nikolai Kosjar
c51195d9bb Git: Specify shotcurts in StashDialog
Change-Id: I05eabdd146f66a908e0cf44f229a0a2e6efe4f93
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-12 14:57:41 +02:00
Orgad Shaneh
709920e013 Git: Fix expecting changes in executeGit
Calling setExpectChanges after execute is too late

Change-Id: I852c224206fcd758943252029b8e9b050920ca5c
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-12 10:15:00 +02:00
Orgad Shaneh
2073a0660f Git: Ensure documents are saved before executing destructive calls
Change-Id: I9ec0ae0ff6a1b70e5d4c322dbf2e53be57e3009f
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-11 22:46:57 +02:00
Andre Hartmann
f1ed40a02c Git: Add Gerrit to Locator
The Gerrit dialog itself was missing while Push to Gerrit was already
there.

Change-Id: Ie4b85cad9dba96beafb595c505daf28d0a1ceeb5
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
2013-06-11 16:24:47 +02:00
Orgad Shaneh
eb2a359f06 Gerrit: Close write channel for fetch process
Change-Id: I1557d2e57f5838d7820bcb41190ff2bb4b9a0473
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2013-06-11 15:11:18 +02:00
Orgad Shaneh
f6833168ac Git: Capitalize display name
Change-Id: I1274cf39ad02e214c64b0ca3308381adae2a5a80
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-11 12:32:33 +02:00
Orgad Shaneh
161b016aa1 Git: Fix title for Fixup Commit
Change-Id: I9d2e9f76a165a57588c29bc1db1a087fc7cb441b
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-11 12:32:07 +02:00
Orgad Shaneh
69d0d6cdca Git: Style fixes
Change-Id: I600e939e99de77e92de1ff068a5ebad98eb736ca
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-11 10:30:55 +02:00
Orgad Shaneh
5cb29aec0b Git: Initialize ConflictHandler before executing command
expectDirectoryChange is called by ConflictHandler. After the command
is executed it is too late

Change-Id: I27e82fd2a979a043932b4a838f3736cbe0f60107
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-11 10:30:43 +02:00
Petar Perisin
7fffe3cef6 Git - Get changes actions dialog back to where it was
This dialog was before, in QtCreator 2.7, used only for show. It was in
main git menu, and available always. Although a lot of new options were
added to the dialog, I think it is good to get it back to where it was
before, so that 2.7 users can find it easier.

Also, I prefer this location for it, since it is easier to access here.

Change-Id: I510ab0efb081194e70f6297125012034103e13e1
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-10 12:07:39 +02:00
Orgad Shaneh
96a0920440 Git: Use file directory as editor source for files opened inside git dir
* git rev-parse --show-toplevel doesn't work inside git dir.
* Only "Describe (show)" should be available for those files. show
  works when running from inside the git dir

Change-Id: If5f3d1af8da2f8d149ac1e03ffd70b530e609557
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-10 10:38:23 +02:00
Orgad Shaneh
879012a50b Git: Mark forgotten cases as expected to change
* When mergetool is done
* Stash
* Stash pop
* Continue/skip command
* executeAndHandleConflicts
* Interactive rebase

Change-Id: Ic8108b096c367c7777dae06f7ff255999d64fda9
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-10 10:38:00 +02:00
Orgad Shaneh
0bd5e79bc7 Git: Disable cherry-pick and revert for commit message and int. rebase
These editors are usually opened when a process is in progress, so
it doesn't make sense to allow reverting or cherry-picking for them

Change-Id: I6f238ef973be86d07d2646bcea969f9aa2742b9d
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-10 10:37:47 +02:00
Orgad Shaneh
808f4492c5 VCS: Add a property to Command to indicate expected repo changes
Change-Id: Ia6c929ae64008dcb37695a5358c44096a893e0c4
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-10 10:37:36 +02:00
Orgad Shaneh
aae82f0e29 Git: Add using VcsBase::VcsBasePlugin
Less noise

Change-Id: I5c13af770f04ae411b09ed824cf93d2768b8e224
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-10 10:37:29 +02:00
Orgad Shaneh
050d13726a Gerrit: Replace --remotes with -r for "git branch"
--remotes was added in 1.7.7

Change-Id: I691bfada8e0b4d2f00924caa76271ee256edf62c
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Petar Perisin <petar.perisin@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-10 10:31:23 +02:00
Orgad Shaneh
e8c1b8b739 Git: Remove unused forward declarations
Change-Id: I1926733dc88902e75921a6bfa184e3f6b27ce98d
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-10 10:25:43 +02:00
Orgad Shaneh
029fd5a572 Streamline mimetypes.xml files
Change-Id: I4f2a28d4732ea496f574e5f51fb1e1633ebca99d
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2013-06-07 16:23:19 +02:00
Eike Ziller
1b3bb5cb7e Consistently give qbs groups a name.
These nicely show up in the project tree in Qt Creator then.

Change-Id: I9782f5953d61940e6c2a0f61f07bb15aaeba49d9
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2013-06-06 13:40:51 +02:00
jkobus
5e407c08d7 Remove \r from git process output
Task-number: QTCREATORBUG-9443
Task-number: QTCREATORBUG-9448

Change-Id: I02e65eab6be5d129b605067425f6774550fbf511
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2013-06-06 13:28:07 +02:00
Petar Perisin
bf3c8601ef git - add files for commit that are inside untracked folders
However, files need to be part of the current project to be added to the
list.

Task-number: QTCREATORBUG-9153
Change-Id: Ifb7a4684e85d0ccd688956eeff77b4cc7d807911
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2013-06-05 21:48:44 +02:00
Orgad Shaneh
164955a4e0 Git: Use top level for stash working directory
The message in stashPrompt doesn't make sense with an inner directory

Change-Id: Iddbea519915cd22a6882dcafb705d1ed99106db6
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2013-06-05 18:32:29 +02:00
Petar Perisin
d567c60061 Git - bugfix with empty string in findRepositoryForDirectory
Change-Id: I44f68ad59d10e9751d09ed6e0f959d2a78d53822
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2013-06-05 17:02:22 +02:00