Commit Graph

402 Commits

Author SHA1 Message Date
Marcus Tillmanns
1fabd72514 DeviceSupport: Add more error output
Previously most errors when opening shells were completely
opaque to the user. This patch adds error output either via
QMessageBox if there is another modal dialog, or as flashing
disrupting messages.

Change-Id: I54be7a90295b61c23c739294c2d1d37c288ad273
Reviewed-by: hjk <hjk@qt.io>
2023-10-06 08:26:15 +00:00
Marcus Tillmanns
d79c69918f Docker: Add clangd path to sdktool
This patch also allows the user/installer to supply a path without
the device root, to make it easier for the installer.

Fixes: QTCREATORBUG-29694
Change-Id: I641b06dd2f4a9d94079fb26f2ed949c5246c1c1e
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2023-10-05 08:54:23 +00:00
Marcus Tillmanns
39354fd5e1 Docker: Add missing display style for extraArgs
Change-Id: I09150ee63ab9911e4f1ae555575b068e4f93d5fa
Reviewed-by: hjk <hjk@qt.io>
2023-10-04 13:34:34 +00:00
Marcus Tillmanns
c50f9a9273 Docker: Move rootPath into Settings
Change-Id: I11aa1d928281b13ccb136b907c9eb8f98582fd28
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-10-04 12:34:10 +00:00
Marcus Tillmanns
c999f4f880 Docker: Fix threading
Make sure that the container state is synchronized
with the main thread.

Change-Id: I8b50a380779038b273a1eb6645aa08309e90bc56
Reviewed-by: hjk <hjk@qt.io>
2023-10-04 12:34:04 +00:00
Marcus Tillmanns
ee51a1cbdf Docker: Remove superfluous default
Change-Id: I05eee8021b48dae49cfe3a97a4bc8f89550b51be
Reviewed-by: hjk <hjk@qt.io>
2023-09-25 07:43:56 +00:00
Marcus Tillmanns
3c5de27af4 Docker: Cleanup
Change-Id: I38a0b3177bea4276b3758a6a2ecfd24118be15e3
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-09-21 12:46:38 +00:00
Marcus Tillmanns
d3f060a754 Docker: Show create command line to user
Change-Id: I740d2647e2033c841fe6926b273b06ce45ecb0e7
Reviewed-by: hjk <hjk@qt.io>
2023-09-21 09:15:54 +00:00
Marcus Tillmanns
ada5aacedb Docker: Add extra arguments setting
Change-Id: I3cd30001defb99ce6f23b31935dc3a21ce60a256
Reviewed-by: hjk <hjk@qt.io>
2023-09-21 08:17:45 +00:00
Marcus Tillmanns
189cf8054f Docker: Add network option to settings
Change-Id: Idb18435aa668f9219ae0eb2db6bd55d040ba5243
Reviewed-by: hjk <hjk@qt.io>
2023-09-20 08:02:04 +00:00
Marcus Tillmanns
5109b0ce0e Docker: Fix default device name
Change-Id: I1d7e8dd62a11cf897ebb22389f21370c8a3811cf
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-09-18 06:48:51 +00:00
Marcus Tillmanns
b81026488c Docker: Improve error reporting
Change-Id: I1a1ad824b4084ce7203357acf9ec19ccfe91b5cd
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2023-09-15 13:00:39 +00:00
Marcus Tillmanns
0c157b4ba6 Docker: Use FileListAspect for mounts
Change-Id: I6392c8bb8ebdfb0984f56ebda23567ef8b42bb6a
Reviewed-by: hjk <hjk@qt.io>
2023-09-12 08:51:39 +00:00
Marcus Tillmanns
f6205d6cc7 Docker: Switch to aspect settings
Change-Id: Id04c48caf2ddd33e176ee424273690b80c77232b
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-09-12 08:51:31 +00:00
Marcus Tillmanns
116ad3ed4f ProjectExplorer: Remove IDevice::setDisplayName
also removes IDevice::setDefaultDisplayName

Change-Id: Ie8ac3d95ba1991a20720342de3bf6e97c6414ffa
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-09-11 11:25:34 +00:00
Marcus Tillmanns
9b85b1087f ProjectExplorer: Add Aspect Settings to devices
Change-Id: I4a69945dbb862a2741998a3bbbb0512e5fb829c9
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-09-11 07:29:10 +00:00
hjk
8d0aa34bfc Plugins: A bit more Keys and Store
Change-Id: Iee55eeaa881dd9f2047fdbe95ad8d827f4ba34e0
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-08-25 08:00:02 +00:00
hjk
6e307be365 Utils: Rename the new Storage to Store
Apparently that's what the young people on the web use for such a thing.

Change-Id: I75d5396ff3cb3c26efd6008b5f2261354c4f7896
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-08-24 05:56:57 +00:00
hjk
dc6b40a5c0 Use Utils::Storage instead of QVariantMap in a few places
Change-Id: I02833cf2bc3caaadc22ff93ae530e4aebe4c3868
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-08-23 14:30:50 +00:00
hjk
ec7abcf98c Utils: Make FilePathAspect::setDefaultValue take a QString
This sets the unexpanded value, so going to a "cooked" FilePath can
at least theoretically break. On the user side it saves a
roundtrip in a few cases, but is more ugly when the input is already
a proper FilePath.

Change-Id: I8a7e8f6d46fcc34c96b55e41d656dca933fbef4e
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-08-17 11:58:41 +00:00
hjk
aa25fdcc69 QtSupport: Rename qtkitinformation.{h,cpp} -> qtkitaspect.{h,cpp}
Change-Id: I12229e5e98b468101d32edd35be74bbda0921d89
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-08-15 08:59:52 +00:00
hjk
017d7c0e47 ProjectExplorer: Rename kitinformation.{h,cpp} to kitaspects.{h,cpp}
Change-Id: I069bddeb457366210d339edcbb8ffb359a40fab8
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-08-15 07:31:03 +00:00
Eike Ziller
a419670ff5 Build: Change plugin json.in files to CMake style
They were still using variables in qmake style.
Directly use CMake variables in the json.in files and remove the no
longer needed escaping of quotes.

Adds a fatal message if it detects the old style in a .json.in file for
easier porting.

Change-Id: I8de88d8db2da55781f0e9d72eda03f943723188e
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-07-25 13:21:16 +00:00
hjk
bd24f18dd5 Docker: Simplify plugin definition
Change-Id: If37a8df1292f01f1048549adb135a65fda66a09f
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-14 14:06:37 +00:00
hjk
baf5377b60 Docker: Simplify settings access
Change-Id: I0ecbba9d29b041b06dac26159be702a38db42185
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-14 14:00:23 +00:00
Eike Ziller
26e96bfad8 Merge remote-tracking branch 'origin/11.0'
Conflicts:
	src/plugins/debugger/debuggeritemmanager.cpp

Change-Id: I9d99d13feff9315f52eacbd84857c63cb69bf804
2023-07-03 10:24:09 +02:00
hjk
5b93ecdd05 Docker: Add sanity check in start container
Change-Id: I633685402f27a3af317a58fd6f3c1d58174db989
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-06-30 11:44:00 +00:00
hjk
98bba063b6 Utils: Use FilePathAspect::setDefaultValue
... instead of StringAspect::setDefaultFilePath.

Closer to the intended uniform access.

Task-number: QTCREATORBUG-29167
Change-Id: I87df385ef98873a0955010149a9a9b09a5f29daf
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-06-30 09:34:26 +00:00
hjk
a62fcb73ce ProjectExplorer: Remove IDevice::createProcessListModel
All re-implementations are the same nowadays.

Change-Id: I954b3c9ca296967a99ea548ade6282fba188249f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-06-23 12:27:03 +00:00
hjk
d045d8dc60 ProjectExplorer: Merge DeviceProcessList into ProcessList
The abstraction was not used anymore.

Change-Id: I756ae65b9164d0032c3e6a26c3a123fc50f72a75
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-06-23 12:21:39 +00:00
Marcus Tillmanns
ffa52040a4 Docker: Fix ensureReachable
ensureReachable for a path on the same device must return true.

Change-Id: I5b6924795997758ec0ad31520fa971ecd2a9615c
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-06-23 10:40:42 +00:00
Leena Miettinen
942f30d461 Docker: Fix UI text
- Write Docker with an initial capital letter
- Rewrite a tooltip to add reasons for adding a flag first, and
  then the flag.

Change-Id: I8b4f3775ad618999faddec90b62ba7bb11ac23ae
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-06-19 11:05:45 +00:00
hjk
a6848e2026 Docker: Register settings aspect more directly
Change-Id: Iaf36d476f53eab459cba4d0e64e55b73a395beea
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-05-30 09:12:16 +00:00
hjk
2ca7aff073 Docker: Remove DockerPlugin::dockerApi()
Access is nowadays via DockerApi::instance()

Change-Id: Idc1530358771c3a008182661c263c30b68fe84be
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-05-25 08:48:18 +00:00
hjk
6f31d87444 Use more FilePathAspect
Change-Id: Ib348df1460f8610607251498b07010df58d51ddf
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-19 15:07:17 +00:00
hjk
6c5fb656d6 Utils: Make PagedSettings::readSettings() calls shorter
Ideally, this would not be needed on the user code side at all, but
there's no way to ensure the settings are read timing before sibling
constructors might need it. So keep the 'poor man's two-phase
initialization', but make it less intrusive.

Change-Id: Ica7f6510cd05072d7286f4e85cd72c494e8f10f8
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-16 16:36:25 +00:00
hjk
5614696002 Core: Make PagedSettings autoapply by default in the base
Instead of relying (and forgetting...) it in all derived clases.

Change-Id: I5d1dea0ace420d464c39c192278ae6e5db01de90
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-11 13:43:58 +00:00
hjk
98d9ad8b3c Docker: Use PagedSettings
More compact.

Change-Id: Ic21c6ea9e7faf67e5f507f336f18e1134b371a97
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-10 16:23:21 +00:00
Marcus Tillmanns
e6081aaa0a Utils: Add TerminalMode::Detached
Change-Id: Ic36845d3469719e17f24602ce80f3e6cfc984fbf
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-05-04 10:43:36 +00:00
Jarek Kobus
a0f6e8dc04 Utils: Rename qtcprocess.{cpp,h} -> process.{cpp,h}
Follows QtcProcess -> Process rename.

Change-Id: I97235a9a40cb7fd52944515b7ab878d96528f919
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-05-04 05:52:26 +00:00
Jarek Kobus
470c95c94b Utils: Rename QtcProcess -> Process
Task-number: QTCREATORBUG-29102
Change-Id: Ibc264f9db6a32206e4097766ee3f7d0b35225a5c
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2023-05-04 05:52:16 +00:00
hjk
50084f6b0e Layouting: Handle attach types via setter
Change-Id: I862f5cd109db3582b4f029787ec0cded2da39ce6
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-03 13:44:19 +00:00
Jarek Kobus
a3a5b8f806 Utils: Rename asynctask.{cpp,h} -> async.{cpp,h}
Follows AsyncTask -> Async rename.

Change-Id: I37f18368ab826c9960a24087b52f6691bb33f225
Reviewed-by: hjk <hjk@qt.io>
2023-05-03 13:24:20 +00:00
Marcus Tillmanns
ccbab62461 Docker: Make end of auto detection obvious
Fixes: QTCREATORBUG-28819
Change-Id: I2d93c472ed7b29329642cb8052b6f7b980d017d9
Reviewed-by: Janne Juntunen <janne.juntunen@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-04-06 11:20:12 +00:00
Marcus Tillmanns
522de9bfd7 Devices: Unify Port Gathering method
All devices that support it use the same mechanism to gather ports
so this patch removes the individual implementations in favor
of a single one in IDevice.cpp.

This patch also removes:
* canAutodetectPorts() as it was not used.
* Port::parseFrom...Output as they are not used anymore.

Change-Id: I8ecedec2d71e60985402387982c64311c5a651e6
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-04-06 06:58:44 +00:00
Marcus Tillmanns
c378df273c Docker: Fix windows terminal
Do not send the marker when running in a PTY. On windows it gets encased
in junk and duplicated otherwise.

Change-Id: I9017066b0f1d22d4700704bfa2120c4f5d66daa9
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-04-05 09:15:24 +00:00
hjk
de546ff3ec Debugger: Support piping dumpers into gdb
This allows using dumpers available on the host being used from
remotely running gdb. No lldb/cdb yet.

Task-number: QTCREATORBUG-29000
Task-number: QTCREATORBUG-16246
Change-Id: Ib1a40a8c0284dcf41e8800d70ca3e632c699b2fa
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-04-05 06:26:11 +00:00
hjk
305ccfe259 Utils: Replace FilePath::onDevice() by new FilePath::withMappedPath()
Basically a.onDevice(b) == b.withNewMappedPath(a), matching the order
of b.withNewPath(a).

Whether the (curretly docker-specific) path mapping is useful /there/, and
whether some of the calls are needed at all is dubious. I added some
FIXME and changed a few cases directly.

Change-Id: I7514736ce922f632f1f737bc496f6783389a42b6
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-04-04 06:56:55 +00:00
Marcus Tillmanns
b999e5700e Terminal: Fix docker cmd for terminals
* Fix env for terminals

Change-Id: Ie16a74aeca3ad34a76af1dee0c5a01e607aabebb
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-04-04 05:59:35 +00:00
Marcus Tillmanns
f1f5a7412a Utils: Send __qtc marker from stub
Docker and ssh devices need the real process id on the
remote device. The process stub now send this if it receives
it as the first line of output.

Change-Id: I5d3af39651958fc88d21c3854a0fa1d7f51547a6
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-04-04 05:59:25 +00:00