aboutsummaryrefslogtreecommitdiffstats
path: root/src/libs/utils/synchronousprocess.h
Commit message (Collapse)AuthorAgeFilesLines
* Use Utils::FilePath in SynchronousProcesshjk2019-06-111-6/+0
| | | | | | | Adapt callers and surrounding code. Change-Id: Ie6c1883a44169cf9d790d06b660f46d24dc24c89 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Utils: Add a CommandLine::splitArguments() convenience functionhjk2019-06-061-1/+8
| | | | | | | | ... and use it from within new SynchronousProcess functions taking CommandLine arguments. Change-Id: I5d7f83727cbb22f03b1a79b1645db95514c66033 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Fix debugging on Android arm64/x86_64BogDan Vatra2018-10-041-1/+1
| | | | | | | | On Android 64, there is no lib/ symlink anymore, so we need to upload gdbserver from QtCreator. Change-Id: Ib6f6d9b623dc61b72dd434ce1b3b409e880bdeaa Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
* Utils: Consistently use nullptrTobias Hunger2018-05-131-2/+4
| | | | | | | Fixed by clang-tidy modernize-use-nullptr. Change-Id: I93edae67271a521e3b2a1f97f486e5fa97009836 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Utils: Use override consistentlyTobias Hunger2018-05-131-1/+1
| | | | | | | clang-tidy fixes from modernize-use-override check. Change-Id: I89d27f359b6ee507153cb3712f61f81471ff0858 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* SynchronousProcess: Make sure there always is a codecTobias Hunger2016-07-211-1/+1
| | | | | | | Task-number: QTCREATORBUG-16628 Change-Id: I037acc37d8e3df88050a3853734c7f4c99e52b6b Reviewed-by: Tim Jenssen <tim.jenssen@qt.io> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* SynchronousProcess: Small cleanupsTobias Hunger2016-07-211-6/+6
| | | | | | | * Use class, not struct, according to coding style Change-Id: I3aa14eb9f480d7b07fb015b8694aae6fcc60c169 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* SynchronousProcess: Store raw bytes from stdout/stderr of the processTobias Hunger2016-07-151-11/+12
| | | | | | | | | | | | | | | Only convert the raw output later in a stdOut() and stdErr() method of the SynchronousProcessResponse. This is necessary since we have processes that use different encodings for different sections of the file (I am looking at you, git). Also remove the signals for raw data on stdout/stderr, leaving only the signals returning buffered QString lines. This should be safe, even with UTF-16 output. Change-Id: Ida613fa86d1468cbd33bc6b3a1506a849c2d1c0a Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* Utils: De-slot and complete Qt5 connectsOrgad Shaneh2016-06-291-3/+1
| | | | | | | The only Qt4-style [dis]connects left are in BaseTreeView::setModel. Change-Id: I53bb715750c65827005cc96939a6714606e60f81 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* Utils: Add fully blocking way to run a binary to SynchronousProcessTobias Hunger2016-05-261-0/+3
| | | | | | | | This does not use a nested event loop. Change-Id: I581acdd07546dc633ff4ce371c69b72a6f6c7a8f Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com> Reviewed-by: Vikas Pachdha <vikas.pachdha@theqtcompany.com>
* Fix up QProcess::waitForFinished()Tobias Hunger2016-05-111-0/+1
| | | | | | | | waitForFinish returns false if the process is no longer running at the time of the call. Handle that throughout the codebase. Change-Id: Ia7194095454e82efbd4eb88f2d55926bdd09e094 Reviewed-by: hjk <hjk@theqtcompany.com>
* Fix build with clang on LinuxTobias Hunger2016-04-271-0/+2
| | | | | Change-Id: I9228554c5ed4d0a364f3fa71fc88dcf529391e1e Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* SynchronousProcess: Change exit code interpreter to function objectEike Ziller2016-04-271-9/+4
| | | | | | Change-Id: Ic48d4f5810f171c070f0980581fb6e45f6fe6b4a Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* Wholesale conversion to #pragma oncehjk2016-03-301-4/+1
| | | | | | | Kudos to cgmb and https://github.com/cgmb/guardonce Change-Id: Ifa8970734b8d43fd08c9260c645bdb0228633791 Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
* Update License according to agreement with Free Qt FoundationTobias Hunger2016-01-191-17/+12
| | | | | | | * Update remaining files in src Change-Id: I1896f17fcf34f71c3310c87899fb5171b8e4afb1 Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
* Utils: Make SynchronousProcess use second based timeoutsOrgad Shaneh2015-04-151-4/+4
| | | | | Change-Id: Ie2de2359225017cae7181bee0df17542fa36efd8 Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
* Update LicenseEike Ziller2015-01-161-6/+6
| | | | | Change-Id: I711d5fb475ef814a1dc9d2822740e827f3f67125 Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
* License updateEike Ziller2014-10-091-7/+8
| | | | | Change-Id: I3c22ef2685d7aa589f5d0ab74d693653a4c32082 Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
* Incremented year in copyright infoRobert Loehning2014-01-081-1/+1
| | | | | | Change-Id: Ib5423fdd064e4546f848c0b640b0ed0514c26d3a Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com> Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Introduce ExitCodeInterpreter, useful when exit code != 0 is validjkobus2013-09-261-0/+11
| | | | | | | Task-number: QTCREATORBUG-10207 Change-Id: I3b440d40a968f09afc613b686ee50da6465ad88e Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
* VCS: Enable terminating a commandOrgad Shaneh2013-09-021-0/+3
| | | | | Change-Id: I2160a22e300aca9b38e28257375c8e0be2026d12 Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
* SynchronousProcess: Replace last QByteArrays with QStringsOrgad Shaneh2013-08-081-7/+5
| | | | | | | | | Matching \n in a QByteArray is wrong. For example, it detects Ċ (U+010A) and ਛ (U+0A1B) as end-of-line Change-Id: I9c03d0b19da3d328e706ff2c89f09713be870f34 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
* Introduce Utils::SynchronousProcess::normalizeNewlinesOrgad Shaneh2013-08-061-0/+2
| | | | | | | | | | | Replaces \r\n? with \n. Some console applications (e.g. git-push, git-rebase) use \r alone to move the cursor to the line's beginning. This should be replaced by \n rather than just be erased. Change-Id: I8d614d2b471e59decdbfa7f173ffa7fbdb11759b Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
* SynchronousProcess: Use the same codec for stdout and stderrOrgad Shaneh2013-07-021-4/+3
| | | | | Change-Id: I4a7e5a5748dd9e16b1e62b3879cce8ccab0f3e01 Reviewed-by: Eike Ziller <eike.ziller@digia.com>
* Clean headers in Utils.Friedemann Kleint2013-03-191-2/+0
| | | | | | | | | | Forward-declare QGraphicsOpacityEffect in DetailsButton, QProcessEnvironment in Environment, QFileInfo in fileutils, QUrl in IWelcomePage, FancyLineEdit in PathChooser and remove unneeded headers. Change-Id: I7d5f273530dd2059bbdaf0899f0a3bc7e49e8482 Reviewed-by: hjk <hjk121@nokiamail.com>
* Merge remote-tracking branch 'origin/2.6'Oswald Buddenhagen2013-01-311-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/autotoolsprojectmanager/AutotoolsProjectManager.pluginspec.in src/plugins/debugger/qtmessageloghandler.cpp src/plugins/debugger/qtmessagelogwindow.cpp src/plugins/madde/maemodeployconfigurationwidget.cpp src/plugins/qmldesigner/components/integration/designdocumentcontroller.cpp src/plugins/qmldesigner/designercore/include/widgetqueryview.h src/plugins/qmldesigner/designercore/metainfo/metainfoparser.cpp src/plugins/qmldesigner/designercore/model/modelnodecontextmenu.cpp src/plugins/qmldesigner/designercore/model/modelnodecontextmenu.h src/plugins/qmlprojectmanager/qmlprojectapplicationwizard.cpp src/plugins/qnx/bardescriptormagicmatcher.h src/plugins/qt4projectmanager/profilekeywords.cpp src/plugins/remotelinux/deployablefilesperprofile.cpp src/plugins/remotelinux/deployablefilesperprofile.h src/plugins/remotelinux/deploymentinfo.cpp src/plugins/remotelinux/deploymentsettingsassistant.cpp src/plugins/remotelinux/profilesupdatedialog.cpp tests/auto/icheckbuild/ichecklib.cpp tests/auto/icheckbuild/parsemanager.cpp tests/auto/icheckbuild/parsemanager.h Change-Id: Ie465a578446a089e1c502d1cb1096e84ca058104
| * Incremented year in copyright infov2.6.2Robert Loehning2013-01-291-1/+1
| | | | | | | | | | Change-Id: Ic6a9ff0359625021ebc061d22db6811814534205 Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* | Merge remote-tracking branch 'origin/2.6'Eike Ziller2012-10-051-21/+20
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: share/qtcreator/qml/qmlpuppet/commands/endpuppetcommand.cpp share/qtcreator/qml/qmlpuppet/commands/endpuppetcommand.h src/plugins/debugger/qtmessageloghandler.cpp src/plugins/debugger/qtmessageloghandler.h src/plugins/debugger/qtmessagelogwindow.cpp src/plugins/madde/maemodeployconfigurationwidget.cpp src/plugins/madde/maemodeployconfigurationwidget.h src/plugins/remotelinux/deployablefilesperprofile.cpp src/plugins/remotelinux/deployablefilesperprofile.h src/plugins/remotelinux/deploymentinfo.cpp src/plugins/remotelinux/deploymentinfo.h src/plugins/remotelinux/deploymentsettingsassistant.cpp src/plugins/remotelinux/profilesupdatedialog.cpp src/plugins/remotelinux/remotelinuxdeploymentdatamodel.h tests/auto/icheckbuild/ichecklib.cpp tests/auto/icheckbuild/ichecklib_global.h tests/auto/icheckbuild/parsemanager.cpp tests/auto/icheckbuild/parsemanager.h tests/manual/ssh/tunnel/tunnel.h Change-Id: I04d7761df6bd936ad00e0547974284c967d39580
| * Adjust license headershjk2012-10-051-21/+20
| | | | | | | | | | Change-Id: Ice592c6de9951ee3b2c4cb52ed0bb3b6770e0825 Reviewed-by: Eike Ziller <eike.ziller@digia.com>
* | HostOsInfo: Add some more useful abstractions.Christian Kandeler2012-09-051-1/+0
|/ | | | | | | | | | | | | Namely: - path list separator - executable suffix - file name case sensitivity All of these are duplicated in various places in the current Creator code. Change-Id: I86eb4662fa3c2071759bd728cae1aaf7111ae686 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Contact -> qt-project.orgEike Ziller2012-07-191-3/+1
| | | | | Change-Id: I7134d7de30bcf9f9dcfad42520dd45ee083a852d Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Removed module names from #include directives.Erik Verbruggen2012-02-151-4/+4
| | | | | | | | Getting the #include directives ready for Qt5. This includes the new-project wizards. Change-Id: Ia9261f1e8faec06b9285b694d2b7e9a095978d2b Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
* Long live the king!hjk2012-01-261-1/+1
| | | | | Change-Id: I2b72b34c0cfeafc8bdbaf49b83ff723544f2b6e2 Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
* all: s/info@qt.nokia.com/qt-info@nokia.com/hjk2011-11-031-2/+2
| | | | | Change-Id: If18afb5d4665924e7d9250dccbc60a65e6daa75e Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
* all: some m_d -> d stylehjk2011-09-081-2/+1
| | | | | | Change-Id: Iac1f12980bf47666007817cfb2c64a6d1e9b780e Reviewed-on: http://codereview.qt-project.org/4477 Reviewed-by: hjk <qthjk@ovi.com>
* Fix/add copyright headersTobias Hunger2011-05-061-1/+1
| | | | Change-Id: I8b73d583be1ee7183f4074bce49d5390e38631a2
* Update license.hjk2011-04-131-14/+13
|
* API-Documentation: Add the Utils-library.Friedemann Kleint2011-03-021-20/+0
| | | | Fix API after doc template change.
* It's 2011 now.con2011-01-121-1/+1
| | | | Reviewed-by: hjk
* License headers.con2010-12-171-7/+11
|
* Synchronous Process: Add a message box for timeouts.Friedemann Kleint2010-05-211-2/+24
| | | | | | | Optionally prompt the user whether a process should be killed after being non-responsive. Do the same with readProcessData. Add a way of creating a process without terminal (UNIX) for suppressing SSH password prompts.
* Long live the king!hjk2010-03-051-1/+1
|
* VCS: Fix time-out handling for synchronous processes.Friedemann Kleint2010-03-011-2/+18
| | | | | | | | | | Introduce static utilities to Utils::SynchronousProcess for synchronous processes that mimicks the handling of Utils::SynchronousProcess (apply timeout after no more data are available on stdout/stderr as opposed to waitForFinished()). Task-number: QTCREATORBUG-777
* Perforce: Use new VCSBasePlugin class.Friedemann Kleint2009-12-111-0/+3
| | | | | | | Use relative paths with -d-option, check for symlinked depots. Add revert-actions. Use different context/kinds for editors, suppressing warnings. Introduce common run-function.
* Rename namespace Core::Utils into UtilsFriedemann Kleint2009-10-051-2/+0
| | | | | Also move Designer::Internal::FormWindowEditor -> Designer::FormWindowEditor.
* long live the kinghjk2009-08-141-1/+1
|
* Fix up the Subversion plugin.Friedemann Kleint2009-07-141-0/+6
| | | | Add some functionality needed for CVS.
* Update license headers and sales contact details.Jason McDonald2009-06-171-2/+2
| | | | Reviewed-by: Trust Me
* Rename QWORKBENCH_UTILS_EXPORT to QTCREATOR_UTILS_EXPORTAlessandro Portale2009-05-081-3/+3
| | | | Rename QWORKBENCH_UTILS_LIBRARY to QTCREATOR_UTILS_LIBRARY
* Fixes: change file license headers to include LGPLhjk2009-02-251-21/+17
|