------概述-----
win 连接 linux,有 3 种情况。
1 win 的 cmd to linux 的 bash
2 win 的 powershellv6,v7 to linux 的 bash
3 win 的 powershellv6,v7 to linux 的 powershell。
------讲解上述情况 2-----
在 powershell 中运行:ssh root@ip
在 win term 中编写
"commandline" : "C:\\Program Files\\PowerShell\\7-preview\\pwsh.exe -noexit -command 'ssh root@ip' ",
------讲解上述情况 3-----
3.1 脚本下载地址:
powershell 入门资料下载:含绝大多数电子书,入门基础资料。
百度 网 盘
/s/1p2zK-BewhursJxDNQnq5PQ
3.2 需求:
需要 linux 中安装 powershell,并改写 sshd 配置文件。
需要先配好 sshkey。
3.3 脚本用途:
3.3.1 在 powershell v6,v7 中,直接运行 ssh_to_centos7.ps1 ,可以进入 linux powershell 命令行。
3.3.2 建议改写 win term 标签配置文件。
{
"commandline" : "C:\\Program Files\\PowerShell\\7-preview\\pwsh.exe -noexit -file d:\\ps\\ssh_to_centos7.ps1",
},
编写并保存后,点击 win term 标签,即可打开远程终端,基本可以代替终端软件。