简体   繁体   English

Sublime Text 2:侧边栏中的SFTP浏览远程

[英]Sublime Text 2: SFTP browsing remote in sidebar

I'm trying to switch to using the SFTP package for Sublime Text 2 as my default FTP client, as it looks rather promising with regards to workflow improvement -- much faster than using a 3rd party FTP client. 我正在尝试切换到使用Sublime Text 2的SFTP包作为我的默认FTP客户端,因为它在工作流程改进方面看起来很有希望 - 比使用第三方FTP客户端快得多。

I was trying to browse a remote server, and it seems like I only have two options: either sync the entire remote location to a local folder, or browse it via the SFTP/FTP > Browse Server menu item, which brings up one of those file browsing bars . 我试图浏览远程服务器,好像我只有两个选择:要么同步整个远程位置到本地文件夹,或通过SFTP / FTP>浏览服务器的菜单项,它会弹出一个浏览它的文件浏览栏 My situation concerns a large remote location (inconvenient to download everything) on which I would like to edit files that are quite spread-out (inconvenient to navigate with that file browsing bar). 我的情况涉及一个大的远程位置(不方便下载所有内容),我想编辑那些非常分散的文件(不方便用该文件浏览栏导航)。

What I'm trying to achieve is to be able to browse the server in the side-bar, like the behaviour that occurs when browsing a local folder, but without actually having to download every single file on the remote location. 我想要实现的是能够在侧栏中浏览服务器,就像浏览本地文件夹时发生的行为一样,但实际上不必下载远程位置上的每个文件。 Just the directory listing should be sufficient information to achieve this. 只是目录列表应该是足够的信息来实现这一点。 Then, upon trying to open a file from the sidebar that hasn't been downloaded yet, it could go ahead and download that specific file. 然后,在尝试从尚未下载的侧栏打开文件时,它可以继续下载该特定文件。

Is this some sort of option I have not yet discovered? 这是我还没有发现的某种选择吗? Where can I configure this behaviour? 我在哪里可以配置此行为? What is your FTP workflow when it comes to editing multiple files on a large remote location? 在大型远程位置编辑多个文件时,您的FTP工作流程是什么?

Mount the remote directory using SSHFS and then edit with ST2, there. 使用SSHFS挂载远程目录,然后使用ST2进行编辑。

SSHFS: SSHFS:

This is a filesystem client based on the SSH File Transfer Protocol. 这是基于SSH文件传输协议的文件系统客户端。 Since most SSH servers already support this protocol it is very easy to set up: ie on the server side there's nothing to do. 由于大多数SSH服务器已经支持这个协议,因此很容易设置:即在服务器端没有什么可做的。 On the client side mounting the filesystem is as easy as logging into the server with ssh. 在客户端安装文件系统就像使用ssh登录服务器一样简单。

Example: 例:

sshfs user@host.com:/server/path /local/path

then 然后

subl /local/path

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM