Configuration file fixes

This commit is contained in:
Gnarwhal 2024-08-01 16:07:35 +00:00
parent 82619349b0
commit ad63a98bdf
Signed by: Gnarwhal
GPG key ID: 0989A73D8C421174

View file

@ -58,13 +58,13 @@ class Config:
sys.exit(1)
self.ssh_port = ssh.get("port")
self.ssh_user = ssh.get("user")
self.ssh_path = ssh.get("directory")
self.ssh_path = ssh.get("path")
if self.ssh_port == None:
self.ssh_port = 22
if self.ssh_user == None:
self.ssh_user = getpass.getuser()
if self.ssh_path == None:
print("Error: 'ssh.directory' cannot be 'None'")
print("Error: 'ssh.path' cannot be 'None'")
sys.exit(1)
def _load_from_file(self, config_path):