A handy Vscode editor plug-in: SFTP

1 minute read

Published:

Today I’ll give an intro of a handy pulg-in which is called SFTP. Actually SFTP is a transfer propotol like FTP. SFTP will update the remote machine with the local change of files. In other words, any change to a local file can be synchronized to a remote machine automatically.

SFTP is applied in many places but this article only focuses how to incorporate it in Vscode editor, my favorite editor.

Usage

  1. Install SFTP plug-in in Vscode.

  2. Press Ctrl+shift+p then a input prompt will pop out. Enter SFTP:config.

  3. Config the sftp.json file.

  4. Choose local files and upload.

  5. The files has been uploaded succsessfully!

Note that:

    • host refers to the ip of a remote machine.
    • username and password are the username and password of a remote machine, which is similar to ssh login.
    • remotePath is the file path in a remote machine.
  1. autoUpload and autoDelete are not recommanded because any misoperation will be updated on the other side which may bring about disasters.

  2. You can ignore some abundant files by the ignore option, say, .git files.

  3. Downloading from a remote machine to a local machine works as well.