RemoteLinux: Be explicit about the current rsync support

We currently only transfer host->remote device (or back),
not host->host or remote->remote. Inform the user if we
hit an (currently) unsupported combination.

Change-Id: Icd33414d7d0bc2b5db284a62b5d757989f1596c6
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
hjk
2022-10-13 14:14:51 +02:00
parent 9f8243e5cc
commit 541ddd1ff7

View File

@@ -12,6 +12,7 @@
#include <projectexplorer/deploymentdata.h>
#include <projectexplorer/devicesupport/filetransfer.h>
#include <projectexplorer/devicesupport/idevice.h>
#include <projectexplorer/kitinformation.h>
#include <projectexplorer/projectexplorerconstants.h>
#include <projectexplorer/runconfigurationaspects.h>
#include <projectexplorer/target.h>
@@ -152,7 +153,13 @@ RsyncDeployStep::RsyncDeployStep(BuildStepList *bsl, Id id)
BoolAspect::LabelPlacement::InExtraLabel);
ignoreMissingFiles->setValue(false);
setInternalInitializer([service, flags, ignoreMissingFiles] {
setInternalInitializer([this, service, flags, ignoreMissingFiles] {
if (BuildDeviceKitAspect::device(kit()) == DeviceKitAspect::device(kit())) {
// rsync transfer on the same device currently not implemented
// and typically not wanted.
return CheckResult::failure(
Tr::tr("rsync is only supported for transfers between different devices."));
}
service->setIgnoreMissingFiles(ignoreMissingFiles->value());
service->setFlags(flags->value());
return service->isDeploymentPossible();