Sublime Text 2 update right on site

Asked

Viewed 532 times

1

Does anyone know of a way, when I save the file in Sublime Text 2, it update there on the site? It’s not localhost, so I’m always having to upload the file to the server..

  • 1

    Using Filezilla when clicking on a file on the server with the right button and selecting edit it will open the file in its default editor, in the case of sublimetext, by clicking Ctrl+s the Filezilla will ask to upgrade. But making edits directly on the server can be risky. But I suppose maybe your FTP is at work and you do a homeoffice, or something like that. If you work with more than two people I think you should think about a versioning solution like github :)

1 answer

2


You can use the package SFTP, for Sublime Text 2 and 3.

Characteristics:

  • Mapping a local folder to a remote folder.
  • Upload files, folders or just the changes since your last commit.
  • Upload all open files.
  • Delete the remote version of a file.

However the SFTP is not free. A free alternative is the FTPSync which is available for Sublime Text 2 and 3. Some features:

  • Upload and download multiple files and folders.
  • Rename or delete local or remote files.
  • Determine latest remote files on write protection.

To use it just mark the folder containing the files to upload to the file ftpsync.Settings in the following format(this example does not contain all options):

{
    'primary': {
        host: 'ftp.mywebsite.com',
        username: 'johnsmith',
        password: 'secretpassword',
        path: '/www/',

        upload_on_save: true,
        tls: true
    }
}

The skeleton can be simply inserted by going to Preferences Package Settings Ftpsync Setup Ftpsync in this Folder, either using the context menu in the sidebar or via the shortcut CTRL + Shift + P. See the full list of settings here.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.