• 大小: 35.61MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-08-07
  • 语言: 其他
  • 标签: xshell  

资源简介

xshell5 ,家庭/个人免费版。永久使用。个人修改,请指教

资源截图

代码片段和文件信息

def Main():
xsh.Session.Open(“C:\\...\\NetSarang\\Xshell\\Sessions\\New Session.xsh“)
xsh.Screen.Synchronous = True #True or False
xsh.Session.Sleep(1000)

#*** WaitForString ***
xsh.Screen.WaitForString(“aaa“) # input “aaa“ in Terminal

#*** Send ***
xsh.Screen.Send(“cat /etc/passwd“)
xsh.Screen.Send(‘\r‘)
xsh.Session.Sleep(1000)

#*** Get Clear ***
ScreenRow = xsh.Screen.CurrentRow - 1
ReadLine = xsh.Screen.Get(ScreenRow 1 ScreenRow 40)
Items = ReadLine.split(‘:‘);
xsh.Dialog.MsgBox(Items[2])
xsh.Screen.Clear()

#*** Property ***
xsh.Screen.Synchronous = False
MsgProp = “Col:“ + str(xsh.Screen.CurrentColumn) + “ “
MsgProp = MsgProp + “Row:“ + str(xsh.Screen.CurrentRow) + “ “
MsgProp = MsgProp + “TermCol:“ + str(xsh.Screen.Columns) + “ “
MsgProp = MsgProp + “TermRow:“ + str(xsh.Screen.Rows) 
xsh.Dialog.MsgBox(MsgProp)

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     文件         111  2019-04-21 12:15  ha_Xshell_25206\注册信息.txt
     文件      704208  2019-04-20 22:41  nslicense.dll
     目录           0  2018-01-07 13:59  ha_Xshell_25206\
     目录           0  2018-01-07 12:48  ha_Xshell_25206\Xshell+Xftp\
     文件         823  2016-08-13 22:21  ha_Xshell_25206\Xshell+Xftp\!卸载.bat
     文件        3391  2016-06-21 18:00  ha_Xshell_25206\Xshell+Xftp\!绿化.bat
     文件      165656  2016-07-28 13:27  ha_Xshell_25206\Xshell+Xftp\CrashRpt.dll
     文件      983832  2016-07-28 13:27  ha_Xshell_25206\Xshell+Xftp\CrashSender.exe
     目录           0  2018-01-07 12:48  ha_Xshell_25206\Xshell+Xftp\Languages\
     文件      295936  2016-07-28 13:24  ha_Xshell_25206\Xshell+Xftp\Languages\XagentCHS.dll
     文件     1229824  2016-07-28 13:25  ha_Xshell_25206\Xshell+Xftp\Languages\XftpCHS.dll
     文件      393728  2016-07-28 13:26  ha_Xshell_25206\Xshell+Xftp\Languages\XshellCHS.dll
     文件      763392  2016-07-28 13:26  ha_Xshell_25206\Xshell+Xftp\Languages\XshellCoreCHS.dll
     文件      257024  2016-07-28 13:26  ha_Xshell_25206\Xshell+Xftp\Languages\XtransportCHS.dll
     文件      136408  2016-03-25 17:39  ha_Xshell_25206\Xshell+Xftp\NsCopyHook2.dll
     文件       58928  2013-08-08 10:21  ha_Xshell_25206\Xshell+Xftp\NsNotifier.exe
     目录           0  2016-08-13 22:15  ha_Xshell_25206\Xshell+Xftp\scriptSample\
     目录           0  2018-01-07 12:48  ha_Xshell_25206\Xshell+Xftp\scriptSample\Screen\
     文件         950  2014-10-21 11:43  ha_Xshell_25206\Xshell+Xftp\scriptSample\Screen\xshell_screen.js
     文件         894  2015-07-21 14:15  ha_Xshell_25206\Xshell+Xftp\scriptSample\Screen\xshell_screen.py
     文件         934  2014-10-21 11:43  ha_Xshell_25206\Xshell+Xftp\scriptSample\Screen\xshell_screen.vbs
     目录           0  2018-01-07 12:48  ha_Xshell_25206\Xshell+Xftp\scriptSample\Session\
     文件        1021  2014-10-21 11:40  ha_Xshell_25206\Xshell+Xftp\scriptSample\Session\xshell_session.js
     文件         959  2015-07-21 14:15  ha_Xshell_25206\Xshell+Xftp\scriptSample\Session\xshell_session.py
     文件         948  2014-10-21 11:39  ha_Xshell_25206\Xshell+Xftp\scriptSample\Session\xshell_session.vbs
     目录           0  2018-01-07 12:48  ha_Xshell_25206\Xshell+Xftp\Theme\
     文件        1213  2014-03-27 13:43  ha_Xshell_25206\Xshell+Xftp\Theme\NsTheme.ini
     文件      307480  2016-07-28 13:27  ha_Xshell_25206\Xshell+Xftp\Xactivator.exe
     文件      375064  2016-07-28 13:27  ha_Xshell_25206\Xshell+Xftp\Xagent.exe
     文件     2096920  2016-07-28 13:27  ha_Xshell_25206\Xshell+Xftp\Xftp.exe
     文件      717080  2016-07-28 13:27  ha_Xshell_25206\Xshell+Xftp\Xshell.exe
............此处省略18个文件信息

评论

共有 条评论