This replaces the ProcessInterface::waitFor...() methods.
It's not obligatory to provide this interface when
implementing ProcessInterface subclass. In this case
generic blocking implementation will be used.
The generic implementation usually isn't as efficient as
the custom one, however, for some sophisticated implementations
of process interface, like e.g. SshProcessInterface, providing
custom implementation is really difficult and error prone.
That's why we try to keep a balance: we provide two custom
implementations for QProcessImpl and for ProcessLauncherImpl,
as they are relatively easy to implement, and rely on
generic implementation for others.
Change-Id: Ifc8bd354479ec67b2e8f74f1510f8de8883e9b94
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
That was part of the initial Proof of Concept and is not needed anymore,
the normal build steps can nowadays be remote.
Change-Id: Ic69ff89ebdcf8e6aef73d71954a48501c68c60ff
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Add a setter and getter for reaper timeout. This makes it
possible to customize the timeout for the reaper after which it
should call kill() when previous terminate() was unsuccessful.
This setting is also used for QtcProcess::stop().
Change-Id: I653a3ad107ae4173bb8254c85cfc07886bf6a9c6
Reviewed-by: hjk <hjk@qt.io>
Previously the runInShell and outputForRunInShell methods were
exclusively processed single threaded, meaning all calls
were processed sequentially. With the multiplexed
helper script we can now run multiple processes simultaneously.
( see tst_manual_deviceshell )
Additionally the new script allows us to capture both
stdout and stderr from commands which was not possible previously.
Change-Id: I52f4fb46d872dc274edb9c11872d2f6543741b34
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
More descriptive, and later implementable without full expansion.
Change-Id: Ic3b17ea0b07273f292827a7b63e7695b4bd1cf23
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
... by creating them with the right device to start with.
Change-Id: Ib2f0f10b67322fe66a609287a629d3d720d83c93
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
... and drop QtcProcess::removeEnvironment()
This shifts the meaning of the unqualified QtcProcess::environment()
to always refer to (possibly remote) "main" process this QtcProcess
wraps. The controlEnvironment is now referring to secondary helper
processes (if any...) typically(?) running on the host system.
This helps to avoid local/remote distinctions in some places.
Change-Id: Ib7cd15dd226617484b5358acd7deaed29e751883
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* Added -mindepth 1 to not return the directory that is being searched in.
* Added parenthesis around -type options to correctly express that files OR directories
should be searched, without affecting the following parameters.
* Added parenthesis around -readable, -writeable and -executable and added -o between them,
to correctly indicate that any of the selected type should be searched for.
Change-Id: Ibc77a2a99826663b88015e8f43b5664563384127
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Centralize some boiler plate and warn about best-guessed cases.
Keep the QByteArray based access as writeRaw()
Fixes: QTCREATORBUG-27445
Change-Id: I948d80fba78b36cf85cc73664175ab05eb7707d4
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
This is fully controlled by QtcProcess itself, so provide
general implementation of state() inside QtcProcess.
Task-number: QTCREATORBUG-27358
Change-Id: Id6f0b771ed933f870b80d6856c6d94896f946516
Reviewed-by: hjk <hjk@qt.io>
* Added returning the Id after detecting CMake so it can be set in the autodetected kit
* Trying to keep autodetect from adding the same Qt installation twice if qmake is linked in /bin and /usr/bin
* Added FIXME for RunControlPrivate::runConfiguration as it is used after free in rare cases
* Fixed IosCompilerDetector to not just run if a device is set
* Fixed QnxCompilerDetector to not just run if a device is set
* Fixed auto-detected debuggers not being set as auto-detected, as they now can be removed from the device screen
Change-Id: Ia7772c454d70e147e4326efacc4a6a888fa26782
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Changed daemon state to actually check the docker runtime to determine
if its available or not.
Change-Id: I9e183658dfc7c34e229aec2a332cf303793284e5
Reviewed-by: hjk <hjk@qt.io>
Moved DockerDeviceWidget and KitDetector into their own files
Change-Id: I16d52a4f27f611b6278e2144c4718bd370f99b63
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
The common use case shares project sources between host and docker
container, in that case, not sharing anything will not be useful.
Change-Id: I44b12089579ead008023caf5134c613fc145b8c7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
When retrieving the list of images there is no indicator when
something failed, so add one.
Change-Id: I2e0cde4ba33527e1b2abeecb5b3a06507dabf472
Reviewed-by: hjk <hjk@qt.io>
Also set focus to the line edit when this item gets selected,
and remove the arbitrary /usr/bin;/opt default.
Slightly better UX.
Change-Id: Icdc4e81d6cebd7aed1dd4999c4007a60c8ea53a2
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Move remaining device member to subclasses where needed.
Change-Id: I1a872315579c7f6529e8937d57511a9e99e06926
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
DeviceProcess doesn't provide any public API, so
replace all usages of it with QtcProcess.
Keep using DeviceProcess only for reimplementations.
Change-Id: I35a14251a81dd0dde426f56ca2e809b527cc863c
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Accept (percent-encoded) repo:tag, the image id or the device id as
host() part of a docker FilePath.
Task-number: QTCREATORBUG-26856
Change-Id: I27d374be31d54bab77d129e19884b7f7fd93daa0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
I gave up on the idea, and even leaving the dead code in only
complicates the codebase.
Change-Id: If144c69adc8e9aa9b2c88050909e7a20b7218f18
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This includes replacing DeviceProcess terminal handling with base
member.
Change-Id: Id1541bfce33c71dddc71b4816ad0b174dce3879c
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
So far this had been restricted to Unix, but it works on
all platforms.
Change-Id: I578623341c906eca80a0dbc5fcc9b15e820d3597
Reviewed-by: David Schulz <david.schulz@qt.io>
Makes configurations a bit better exchangable (sdktool...).
Change-Id: Ia566a516afea2205c973527e02ce5664634ebbdc
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
That's sufficient for testing/working on the feature and removes
accidental use by users.
Change-Id: Ic0fb3076f769ab9ab7ff74973f0129402db7f142
Reviewed-by: Christian Stenger <christian.stenger@qt.io>