public async Task<bool> TryHandleCommandAsync(IImmutableSet<IProjectTree> nodes, long commandId, bool focused, long commandExecuteOptions, IntPtr variantArgIn, IntPtr variantArgOut) { _appShell.AssertIsOnMainThread(); if (commandId != RPackageCommandId.icmdSendToRemote) { return false; } var properties = _configuredProject.Services.ExportProvider.GetExportedValue<ProjectProperties>(); string projectDir = Path.GetDirectoryName(_configuredProject.UnconfiguredProject.FullPath); string projectName = properties.GetProjectName(); string remotePath = await properties.GetRemoteProjectPathAsync(); await SendToRemoteAsync(nodes.GetAllFilePaths(), projectDir, projectName, remotePath, CancellationToken.None); return true; }
public async Task <bool> TryHandleCommandAsync(IImmutableSet <IProjectTree> nodes, long commandId, bool focused, long commandExecuteOptions, IntPtr variantArgIn, IntPtr variantArgOut) { _appShell.AssertIsOnMainThread(); if (commandId != RPackageCommandId.icmdSendToRemote) { return(false); } var properties = _configuredProject.Services.ExportProvider.GetExportedValue <ProjectProperties>(); string projectDir = Path.GetDirectoryName(_configuredProject.UnconfiguredProject.FullPath); string projectName = properties.GetProjectName(); string remotePath = await properties.GetRemoteProjectPathAsync(); await SendToRemoteAsync(nodes.GetAllFilePaths(), projectDir, projectName, remotePath); return(true); }