mirror of
https://github.com/veeso/termscp.git
synced 2026-04-06 18:21:44 -07:00
save local file paths in bookmark (#204)
* fix: renamed Bookmark 'directory' to 'remote_path' (keep name in file) * feat: local_path as file transfer parameter and in bookmark
This commit is contained in:
committed by
GitHub
parent
ee28d34f29
commit
ca005cbecd
@@ -220,7 +220,7 @@ pub struct FileTransferActivity {
|
||||
cache: Option<TempDir>,
|
||||
/// Fs watcher
|
||||
fswatcher: Option<FsWatcher>,
|
||||
/// conncted once
|
||||
/// connected once
|
||||
connected: bool,
|
||||
}
|
||||
|
||||
|
||||
@@ -53,7 +53,7 @@ impl FileTransferActivity {
|
||||
/// Connect to remote
|
||||
pub(super) fn connect(&mut self) {
|
||||
let ft_params = self.context().ft_params().unwrap().clone();
|
||||
let entry_dir: Option<PathBuf> = ft_params.entry_directory;
|
||||
let entry_dir: Option<PathBuf> = ft_params.remote_path;
|
||||
// Connect to remote
|
||||
match self.client.connect() {
|
||||
Ok(Welcome { banner, .. }) => {
|
||||
@@ -71,11 +71,11 @@ impl FileTransferActivity {
|
||||
}
|
||||
// Try to change directory to entry directory
|
||||
let mut remote_chdir: Option<PathBuf> = None;
|
||||
if let Some(entry_directory) = &entry_dir {
|
||||
remote_chdir = Some(entry_directory.clone());
|
||||
if let Some(remote_path) = &entry_dir {
|
||||
remote_chdir = Some(remote_path.clone());
|
||||
}
|
||||
if let Some(entry_directory) = remote_chdir {
|
||||
self.remote_changedir(entry_directory.as_path(), false);
|
||||
if let Some(remote_path) = remote_chdir {
|
||||
self.remote_changedir(remote_path.as_path(), false);
|
||||
}
|
||||
// Set state to explorer
|
||||
self.umount_wait();
|
||||
|
||||
Reference in New Issue
Block a user