Add an ssh_arguments configuration file field (#211)
Can be used to add SSH command-line arguments like `-o ConnectTimeout=2`
This commit is contained in:
committed by
Roey Darwish Dror
parent
6dac7a18b2
commit
bfbb486fba
@@ -87,6 +87,7 @@ pub struct ConfigFile {
|
||||
git_repos: Option<Vec<String>>,
|
||||
disable: Option<Vec<Step>>,
|
||||
remote_topgrades: Option<Vec<String>>,
|
||||
ssh_arguments: Option<String>,
|
||||
}
|
||||
|
||||
impl ConfigFile {
|
||||
@@ -270,6 +271,11 @@ impl Config {
|
||||
&self.config_file.remote_topgrades
|
||||
}
|
||||
|
||||
/// Extra SSH arguments
|
||||
pub fn ssh_arguments(&self) -> &Option<String> {
|
||||
&self.config_file.ssh_arguments
|
||||
}
|
||||
|
||||
/// Prompt for a key before exiting
|
||||
pub fn keep_at_end(&self) -> bool {
|
||||
self.opt.keep_at_end || env::var("TOPGRADE_KEEP_END").is_ok()
|
||||
|
||||
Reference in New Issue
Block a user