Editing remote files with vim

Source: Internet
Author: User
Tags ftp ftp protocol rsync
http://denven.blog.hexun.com/11727196_d.html using NETRW plugin: NETRW supports reading and writing files across networks.
Commonly used:
Gvim ftp://username@hostname[:p Ort]/full_directory/filename
Vim ftp://username@hostname[:p Ort]/full_directory/filename

or open vim after the ex command line: E ftp://username@hostname[:p Ort]/full_directory/filename
Although many protocols can be supported, not all protocol systems under Windows are implemented, usually opened with the FTP protocol.

It seems that the plugin is already in gVim7.1. Plug-in latest version 2007-06-20, can also be updated under.
Open the extracted netrw.vba with VIM, execute: So% (requires VIM version at 7.0 and above).


Specific:
Description starting with v66, NETRW REQUIRES VIM 7.0

NETRW supports reading and writing files across networks. One may use the URLs for filenames or one could use NETRW ' s nread and Nwrite commands. NETRW as provided here supports remote and local directory browsing, and supports editing files across the network using  A variety of methods. Bugs to Ndrochip@scampbellpfamily.abizm-nospam.

Example:vim Ftp://user@machine/path

(The following table should be columnar if fixed-width fonts is used in your browser)

REMOTE EDITING
: E dav://machine[:p Ort]/path uses cadaver
: E Fetch://[user@]machine/path uses fetch
: E Ftp://[user@]machine[[:#]port]/path uses FTP autodetects <.netrc>
: E Http://[user@]machine/path uses HTTP uses wget
: E Rcp://[user@]machine/path uses RCP
: E rsync://[user@]machine[:p Ort]/path uses rsync
: E Scp://[user@]machine[[:#]port]/path uses SCP
: E Sftp://[user@]machine/path uses SFTP

REMOTE READING
: Nread? Give Help
: Nread "Machine:path" uses RCP
: nread "Machine path" uses FTP with <.netrc>
: nread "Machine ID password path" uses FTP
: Nread "
dav://machine[:p Ort]/path "uses cadaver
: Nread "Fetch://[user@]machine/path" uses fetch
: Nread "Ftp://[user@]machine[[:#]port]/path" uses FTP autodetects <.netrc>
: Nread "Http://[user@]machine/path" uses HTTP uses wget
: Nread "Rcp://[user@]machine/path" uses RCP
: Nread "rsync://[user@]machine[:p ort]/path" uses rsync
: Nread "Scp://[user@]machine[[:#]port]/path" uses SCP
: Nread "Sftp://[user@]machine/path" uses SFTP

REMOTE WRITING
: Nwrite? Give Help
: Nwrite "Machine:path" uses RCP
: Nwrite "Machine path" uses FTP with <.netrc>
: nwrite "Machine ID password path" uses FTP
: Nwrite "
dav://machine[:p Ort]/path "uses cadaver
: Nwrite "Ftp://[user@]machine[[:#]port]/path" uses FTP autodetects <.netrc>
: Nwrite "Rcp://[user@]machine/path" uses RCP
: Nwrite "rsync://[user@]machine[:p ort]/path" uses rsync
: Nwrite "Scp://[user@]machine[[:#]port]/path" uses SCP
: Nwrite "Sftp://[user@]machine/path" uses SFTP
Http:not supported!

REMOTE DIRECTORY Browsing
: E [Protocol]://[user] @hostname/path/
: Nread [Protocol]://[user] @hostname/path/

LOCAL DIRECTORY Browsing
: E/some/path/to/a/directory

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.