deb: fix bug in find_dsc_file
Some checks failed
CI / build (push) Failing after 5m35s

This commit is contained in:
2026-01-09 23:15:13 +01:00
parent dd62baa455
commit a444a5d8d2
6 changed files with 37 additions and 1 deletions

View File

@@ -244,6 +244,15 @@ impl ContextDriver for SshDriver {
remote_file.write_all(content.as_bytes())?;
Ok(())
}
fn exists(&self, path: &Path) -> io::Result<bool> {
let sess = connect_ssh(&self.host, self.user.as_deref(), self.port)?;
let sftp = sess.sftp().map_err(io::Error::other)?;
match sftp.stat(path) {
Ok(_) => Ok(true),
Err(_) => Ok(false),
}
}
}
impl SshDriver {