From 7cb5321fd0a37a1a75fdce9a5e79d31dc88493ab Mon Sep 17 00:00:00 2001 From: Thierry Parmentelat Date: Thu, 30 Jan 2014 15:50:51 +0100 Subject: [PATCH] cosmetic --- system/TestSsh.py | 4 ++-- system/utils.py | 5 ----- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/system/TestSsh.py b/system/TestSsh.py index e07d97e..595df8f 100644 --- a/system/TestSsh.py +++ b/system/TestSsh.py @@ -29,9 +29,9 @@ class TestSsh: result='' for char in command: if char in "\\\"'<>&|;()$*~": - result +='\\'+char + result += '\\'+char else: - result +=char + result += char return result # check main IP address against the provided hostname diff --git a/system/utils.py b/system/utils.py index cc03318..073c551 100644 --- a/system/utils.py +++ b/system/utils.py @@ -44,15 +44,10 @@ def system(command,background=False,silent=False): ### WARNING : this ALWAYS does its job, even in dry_run mode def output_of (command): import commands -# if options.dry_run: -# print 'dry_run',command -# return (0,'[[dry-run - fake output]]') -# else: (code,string) = commands.getstatusoutput(command) return (code,string) - # convenience: translating shell-like pattern into regexp def match (string, pattern): # tmp - there's probably much simpler -- 2.43.0