FileSystemFactory factory = clientSession.getFactoryManager().getFileSystemFactory();
FileSystemView fs = factory.createFileSystemView(clientSession);
ScpHelper helper = new ScpHelper(channel.getInvertedOut(), channel.getInvertedIn(), fs);
helper.send(Arrays.asList(local),
options.contains(Option.Recursive),
options.contains(Option.PreserveAttributes));
channel.close(false);
}