This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 5 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(9)
看。这已经很老了,但是万一 Google 的人发现了这个,绝对是最好的解决方案 - (而且非常棒) - 就是使用 ConEmu (或包含并构建在 ConEmu 之上的软件包,名为 cmder),然后使用 plink 或 putty 本身连接到特定机器,甚至更好的是,使用 Vagrant 将开发环境设置为本地虚拟机。
这是我能够再次从 Windows 盒子中看到自己发展的唯一方法。
我有足够的信心说,与此相比,所有其他答案(虽然不一定是坏答案)都提供了垃圾解决方案。
更新:截至 2020 年 1 月 8 日,并非所有其他解决方案都是垃圾 - Windows Terminal< /a> 即将实现,并且 WSL 已存在。
Look. This is way old, but on the off chance that someone from Google finds this, absolutely the best solution to this - (and it is AWESOME) - is to use ConEmu (or a package that includes and is built on top of ConEmu called cmder) and then either use plink or putty itself to connect to a specific machine, or, even better, set up a development environment as a local VM using Vagrant.
This is the only way I can ever see myself developing from a Windows box again.
I am confident enough to say that every other answer - while not necessarily bad answers - offer garbage solutions compared to this.
Update: As Of 1/8/2020 not all other solutions are garbage - Windows Terminal is getting there and WSL exists.
从 Windows 10“周年纪念”更新(版本 1607)开始,您现在可以通过启用名为开发者模式的功能,直接从 Windows 内部运行 Ubuntu 子系统。
要启用开发者模式,请转至开始 > 设置,然后在搜索框中键入“使用开发人员功能”以查找设置。在左侧导航栏中,您将看到一个标题为针对开发人员的选项卡。在此选项卡中,您将看到一个用于启用开发者模式的单选框。
启用开发者模式后,您将能够启用Linux子系统功能。为此,请转至控制面板 > 程序 > 打开或关闭 Windows 功能 >并选中显示适用于 Linux 的 Windows 子系统(测试版) 的框。
现在,您可以通过传统的 apt 包直接从 Windows 在 Ubuntu 子系统上通过 bash 运行 tmux,而不是使用 Cygwin 或控制台模拟器(
sudo apt-get install tmux
)。As of the Windows 10 "Anniversary" update (Version 1607), you can now run an Ubuntu subsystem from directly inside of Windows by enabling a feature called Developer mode.
To enable developer mode, go to Start > Settings then typing "Use developer features" in the search box to find the setting. On the left hand navigation, you will then see a tab titled For developers. From within this tab, you will see a radio box to enable Developer mode.
After developer mode is enabled, you will then be able to enable the Linux subsystem feature. To do so, go to Control Panel > Programs > Turn Windows features on or off > and check the box that says Windows Subsystem for Linux (Beta)
Now, rather than using Cygwin or a console emulator, you can run tmux through bash on the Ubuntu subsystem directly from Windows through the traditional apt package (
sudo apt-get install tmux
).tmux 和 GNU Screen 在 cygwin 下工作。它们可以从 cygwin 安装程序安装。只需在那里搜索他们的名字,您可能就会获得最新版本(至少对于tmux)。
Both tmux and GNU Screen work under cygwin. They can be installed from the cygwin installer. Just search for their name there and you probably will get to the latest version (at least for tmux).
替代方案之一是 MSYS2 ,换句话说“MinGW-w64”/Git Bash。您可以简单地ssh连接到Unix机器并从中运行大多数Linux命令。还要安装tmux!
要在 MSYS2 中安装 tmux:
运行命令
pacman -S tmux
要在 < a href="https://git-scm.com/download/win" rel="noreferrer">Git Bash:
安装 MSYS2 并从 MSYS2 文件夹
C:\msys64\usr\bin
到您的 Git Bash 目录C:\Program Files\Git\usr\bin
。One of alternatives is MSYS2 , in another words "MinGW-w64"/Git Bash. You can simply ssh to Unix machines and run most of linux commands from it. Also install tmux!
To install tmux in MSYS2:
run command
pacman -S tmux
To run tmux on Git Bash:
install MSYS2 and copy
tmux.exe
andmsys-event-2-1-6.dll
from MSYS2 folderC:\msys64\usr\bin
to your Git Bash directoryC:\Program Files\Git\usr\bin
.通过将 Console2 与 Putty 或 Plink 结合使用,您也许能够获得所需的内容。
You might be able to get what you want by using Console2 with Putty or Plink.
添加到线程中,镇上有一个名为 babun 的新控制台,我在其中运行 tmux 没有问题。让您运行 bash 或 zsh。
点击此处获取 github
Adding to the thread, there's a new console in town called babun, im running tmux in it without a problem. lets you run bash or the zsh.
click here for github
作为替代方案,SuperPutty 具有选项卡和在多个终端上运行相同命令的选项……可能正是某人正在寻找的。
https://code.google.com/p/superputty/
它还会导入您的 PuTTY 会话。
As an alternative SuperPutty has tabs and the option to run the same command across many terminals... might be what someone is looking for.
https://code.google.com/p/superputty/
It imports your PuTTY sessions too.
这是肮脏的方式:
Here is dirty way:
可以在 Cgywin 中编译和使用 tmux。
http://sourceforge.net/mailarchive/message.php?msg_id=30850840
It's possible to compile and use tmux within Cgywin.
http://sourceforge.net/mailarchive/message.php?msg_id=30850840