npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@ekliptor/ftp-simple

v0.7.5

Published

Simple FTP/SFTP

Downloads

13

Readme

Functions

  • Directly Open, Edit and Save on server files.
  • Save the local file or directory to server(upload and backup option)
  • Download the file or directory from ftp server.
  • Create a directory on the remote server directly.
  • Delete directory(recursive) and files directly from the server.
  • Rename Change the file name on the FTP server.
  • Compare a local file server file.
  • Remote directory open to workspace (Beta version)

Available commands

  • config - Set the ftp connection information.
  • create directory - Create a directory on ftp server.
  • open - Open the file directly from ftp server and when you save upload it to the ftp server.
  • save - File or directory upload to ftp server.(Available from the context menu)
  • download - Download the file or directory from ftp server to the workspace.
  • delete - Delete the file or directory directly from ftp server.
  • rename - Change the file name on the FTP server.
  • diff - Compare a local file server file.
  • Remote directory open to workspace - (Beta version) Open the directory directly on workspace from the ftp server. Similar to remote synchronization. (Caution : So remote delete a files is only possible using 'Delete' in the context menu)

Caution

Be sure to check the console(Ctrl + Shift + U)("OUTPUT -> ftp-simple") for a response to the all action.

Startup Settings

  1. Press 'F1'
  2. Enter 'ftp-simple'
  3. Pick 'CONFIG'
  4. Enter ftp connection information and save

Config setting example

See the easy-ftp details.

  • name - string - Display name.
  • host - string - server domain or ip.
  • port - number - (option) port (Default: : 21)
  • type - string - (option) ftp type. 'ftp' or 'sftp' (Default: : 'ftp'). If 'ftp' does not work, try 'ftp2'.
  • username - string - username for authentication.
  • password - string - (option) password for authentication.
  • privateKey - string - (option) (only sftp) String that contains a private key for either key-based or hostbased user authentication (OpenSSH format) Default: none
  • passphrase - string - (option) Use sftp 'privateKey' only. For an encrypted private key, this is the passphrase used to decrypt it. Default: none
  • agent - string - (option) (only sftp) Path to ssh-agent's UNIX socket for ssh-agent-based user authentication. Important: Windows users: set to 'pageant' for authenticating with Pageant or (actual) path to a cygwin "UNIX socket." Default: none
  • agentForward - boolean - (option) (only sftp) Set to true to use OpenSSH agent forwarding ([email protected]) for the life of the connection. agent must also be set to use this feature. Default: false
  • secure - boolean - (only ftp) Explicit FTPS over TLS, default: false
  • secureOptions - object - (only ftp) Options for TLS, same as for tls.connect() in Node.js.
  • path - string - (option) remote root path. Default: '/'
  • autosave - boolean - (option) To determine whether the automatically uploaded when you open a file directly and modify and save. Default: true
  • backup - string - (option) The local path you want to back up before file saving on the server.
  • confirm - boolean - (option) Only save option. When you save the file, ask if you want to overwrite the file if it already exists.. Default: true
  • project - object - (option) Only save option. Pre-specify local workspace path and server root path to save directly without selecting a path. Overwrite unconditionally.
  • ignore - array - (option) Only 'Remote directory open to workspace' option. Path to be ignore. Use glog pattern. (Caution : server path (ex:/home) + ignore pattern (ex:/**/node_modules) => /home/**/node_modules)

Example

[
	{
		"name": "my server1",
		"host": "127.0.0.1",
		"port": 21,
		"type": "ftp",
		"username": "id",
		"password": "pw",
		"path" : "/"
	},
	{
		"name": "my server1 with tls",
		"host": "127.0.0.1",
		"port": 21,
		"type": "ftp",
		"username": "id",
		"password": "pw",
		"secure" : true,
		//"secureOptions" : {"rejectUnauthorized": false, "secureProtocol" :"TLSv1_2_method"},
		"path" : "/"
	},
	{
		"name": "my server2",
		"host": "127.0.0.1",
		"port": 22,
		"type": "sftp",
		"username": "id",
		"password": "pw",
		"path" : "/",
		"autosave" : false
	},
	{
		"name": "my server3",
		"host": "127.0.0.1",
		"port": 21,
		"type": "sftp",
		"username": "id",
		"password": "pw",
		"path" : "/home",
		"confirm" : false,
		"backup" : "C:/backup",
		"project" :  {
			"c:/projects/project1" : "/home/user/project",
			"c:/projects/project2" : {"path":"/home/user/project2", "save":true}  //When the "save" value is "true", save immediately without confirm
		},
		"ignore" : ["/**/node_modules", "/**/*.class"]
	},
	{
		"name": "my server4",
		"host": "127.0.0.1",
		"port": 22,
		"type": "sftp",
		"username": "id",
		"password": "x",
		"agent": "/run/user/1111/keyring/ssh",
		"path": "/",
		"autosave": true,
		"confirm": false
	},
	....
]

Remote Config(option)

"File - Preferences - Settings" and type in the format shown below.

  • ftp-simple.remote-workspace - string - (option) You can modify the local workspace path when you open a remote file. Modify this option if remote file encoding is not UTF-8.(VSCode appears to have encoding recognition bugs if the workspace path is longer.)
  • ftp-simple.remote-workspace-load-all - boolean - (option) Indicates whether all files are loaded during initial run. If false, the sub folder ([DIR]) will load when it is clicked. Default: true

Example

"ftp-simple.remote-workspace" : "c:/remote-workspace",
"ftp-simple.remote-workspace-load-all" : true