multiSSH3 5.69__py3-none-any.whl → 5.71__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of multiSSH3 might be problematic. Click here for more details.
- multiSSH3.py +11 -7
- {multissh3-5.69.dist-info → multissh3-5.71.dist-info}/METADATA +1 -1
- multissh3-5.71.dist-info/RECORD +6 -0
- multissh3-5.69.dist-info/RECORD +0 -6
- {multissh3-5.69.dist-info → multissh3-5.71.dist-info}/WHEEL +0 -0
- {multissh3-5.69.dist-info → multissh3-5.71.dist-info}/entry_points.txt +0 -0
- {multissh3-5.69.dist-info → multissh3-5.71.dist-info}/top_level.txt +0 -0
multiSSH3.py
CHANGED
|
@@ -54,10 +54,10 @@ except AttributeError:
|
|
|
54
54
|
# If neither is available, use a dummy decorator
|
|
55
55
|
def cache_decorator(func):
|
|
56
56
|
return func
|
|
57
|
-
version = '5.
|
|
57
|
+
version = '5.71'
|
|
58
58
|
VERSION = version
|
|
59
59
|
__version__ = version
|
|
60
|
-
COMMIT_DATE = '2025-05-
|
|
60
|
+
COMMIT_DATE = '2025-05-13'
|
|
61
61
|
|
|
62
62
|
CONFIG_FILE_CHAIN = ['./multiSSH3.config.json',
|
|
63
63
|
'~/multiSSH3.config.json',
|
|
@@ -1191,12 +1191,13 @@ def __handle_writing_stream(stream,stop_event,host):
|
|
|
1191
1191
|
line = '> ' + ''.join(__keyPressesIn[sentInput]).encode().decode().replace('\n', '↵')
|
|
1192
1192
|
host.output.append(line)
|
|
1193
1193
|
host.stdout.append(line)
|
|
1194
|
+
host.lineNumToPrintSet.add(len(host.output)-1)
|
|
1194
1195
|
sentInput += 1
|
|
1195
1196
|
host.lastUpdateTime = time.monotonic()
|
|
1196
1197
|
else:
|
|
1197
1198
|
time.sleep(0.01) # sleep for 10ms
|
|
1198
1199
|
if sentInput < len(__keyPressesIn) - 1 :
|
|
1199
|
-
eprint(f"Warning: {len(__keyPressesIn)-sentInput} key presses are not sent before the process is terminated!")
|
|
1200
|
+
eprint(f"Warning: {len(__keyPressesIn)-sentInput} lines of key presses are not sent before the process is terminated!")
|
|
1200
1201
|
# # send the last line
|
|
1201
1202
|
# if __keyPressesIn and __keyPressesIn[-1]:
|
|
1202
1203
|
# stream.write(''.join(__keyPressesIn[-1]).encode())
|
|
@@ -2263,7 +2264,7 @@ def generate_output(hosts, usejson = False, greppable = False):
|
|
|
2263
2264
|
rtnStr += "User Inputs: \n "
|
|
2264
2265
|
rtnStr += '\n '.join(CMDsOut)
|
|
2265
2266
|
rtnStr += '\n'
|
|
2266
|
-
__keyPressesIn
|
|
2267
|
+
__keyPressesIn[-1].clear()
|
|
2267
2268
|
if __global_suppress_printout and not outputs:
|
|
2268
2269
|
rtnStr += 'Success'
|
|
2269
2270
|
return rtnStr
|
|
@@ -2438,7 +2439,7 @@ def getStrCommand(hosts = DEFAULT_HOSTS,commands = None,oneonone = DEFAULT_ONE_O
|
|
|
2438
2439
|
copy_id = False, unavailable_host_expiry = DEFAULT_UNAVAILABLE_HOST_EXPIRY,no_history = DEFAULT_NO_HISTORY,
|
|
2439
2440
|
history_file = DEFAULT_HISTORY_FILE, env_file = DEFAULT_ENV_FILE,
|
|
2440
2441
|
repeat = DEFAULT_REPEAT,interval = DEFAULT_INTERVAL,
|
|
2441
|
-
shortend = False):
|
|
2442
|
+
shortend = False,tabSeperated = False):
|
|
2442
2443
|
_ = called
|
|
2443
2444
|
_ = returnUnfinished
|
|
2444
2445
|
_ = willUpdateUnreachableHosts
|
|
@@ -2462,7 +2463,10 @@ def getStrCommand(hosts = DEFAULT_HOSTS,commands = None,oneonone = DEFAULT_ONE_O
|
|
|
2462
2463
|
commandStr = '"' + '" "'.join(commands) + '"' if commands else ''
|
|
2463
2464
|
filePath = os.path.abspath(__file__)
|
|
2464
2465
|
programName = filePath if filePath else 'mssh'
|
|
2465
|
-
|
|
2466
|
+
if tabSeperated:
|
|
2467
|
+
return f'{programName}\t{argsStr}\t{hostStr}\t{commandStr}'
|
|
2468
|
+
else:
|
|
2469
|
+
return f'{programName} {argsStr} {hostStr} {commandStr}'
|
|
2466
2470
|
|
|
2467
2471
|
#%% ------------ Record History Block ----------------
|
|
2468
2472
|
def record_command_history(kwargs):
|
|
@@ -2486,7 +2490,7 @@ def record_command_history(kwargs):
|
|
|
2486
2490
|
for name in sig.parameters
|
|
2487
2491
|
if name in kwargs
|
|
2488
2492
|
}
|
|
2489
|
-
strCommand = getStrCommand(**wanted)
|
|
2493
|
+
strCommand = getStrCommand(**wanted,shortend=True,tabSeperated=True)
|
|
2490
2494
|
with open(history_file, 'a') as f:
|
|
2491
2495
|
# it follows <timestamp>\t<strCommand>\n
|
|
2492
2496
|
f.write(f'{int(time.time())}\t{strCommand}\n')
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
multiSSH3.py,sha256=Ynd6Q76wV85vjZUSIavxQePgqWc_4xTObjajioTCFgM,144718
|
|
2
|
+
multissh3-5.71.dist-info/METADATA,sha256=8MsX_mwvDFMX53bwfVi81Gaqp6bjgXfqMhYMOTMQNDc,18093
|
|
3
|
+
multissh3-5.71.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
|
|
4
|
+
multissh3-5.71.dist-info/entry_points.txt,sha256=xi2rWWNfmHx6gS8Mmx0rZL2KZz6XWBYP3DWBpWAnnZ0,143
|
|
5
|
+
multissh3-5.71.dist-info/top_level.txt,sha256=tUwttxlnpLkZorSsroIprNo41lYSxjd2ASuL8-EJIJw,10
|
|
6
|
+
multissh3-5.71.dist-info/RECORD,,
|
multissh3-5.69.dist-info/RECORD
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
multiSSH3.py,sha256=Fh69JiPpBe27zs05RmXa8z1CQmaNXh7hVIZl_RN2iGY,144513
|
|
2
|
-
multissh3-5.69.dist-info/METADATA,sha256=2PFFZiQ4Jck3s1L0DjzHtNerxXPGaxe3maZ8_UOonhU,18093
|
|
3
|
-
multissh3-5.69.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
|
|
4
|
-
multissh3-5.69.dist-info/entry_points.txt,sha256=xi2rWWNfmHx6gS8Mmx0rZL2KZz6XWBYP3DWBpWAnnZ0,143
|
|
5
|
-
multissh3-5.69.dist-info/top_level.txt,sha256=tUwttxlnpLkZorSsroIprNo41lYSxjd2ASuL8-EJIJw,10
|
|
6
|
-
multissh3-5.69.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|