ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

SSHubl

by HorlogeSkynet ST4

:technologist: A Sublime Text 4+ plugin for your SSH connections

Details

Installs

  • Total 183
  • Win 83
  • Mac 51
  • Linux 49
Dec 21 Dec 20 Dec 19 Dec 18 Dec 17 Dec 16 Dec 15 Dec 14 Dec 13 Dec 12 Dec 11 Dec 10 Dec 9 Dec 8 Dec 7 Dec 6 Dec 5 Dec 4 Dec 3 Dec 2 Dec 1 Nov 30 Nov 29 Nov 28 Nov 27 Nov 26 Nov 25 Nov 24 Nov 23 Nov 22 Nov 21 Nov 20 Nov 19 Nov 18 Nov 17 Nov 16 Nov 15 Nov 14 Nov 13 Nov 12 Nov 11 Nov 10 Nov 9 Nov 8 Nov 7 Nov 6
Windows 0 1 0 1 2 3 0 0 0 0 1 0 1 0 1 2 1 0 1 3 0 0 1 2 0 0 0 0 2 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 1 0
Mac 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 1 0 0 0 0 0 0 0 1 1 0 0 0 0 2 0 0 0 0 0 0 0 1 0 2 0
Linux 1 0 1 0 2 0 0 1 0 0 1 0 0 0 0 1 0 0 2 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 1 0 1 0 1 1 1

Readme

Source
raw.​githubusercontent.​com

SSHubl

A Sublime Text 4+ plugin for your SSH connections

Introduction

This plugin aims to grant the power of (Open)SSH to Sublime Text. Included features are :

  • Open a remote terminal
  • Open a remote folder over sshfs
  • Open forward and reverse ports (or UNIX domain sockets)
  • Automatic environment re-setup on project opening

It has been inspired by Visual Studio Code Remote - SSH plugin, without the drawback of depending on a remote agent running on the SSH server.

Dependencies

  • Sublime Text 4081+
  • OpenSSH client
  • sshfs (FUSE) client
  • pexpect Python package (used for non-interactive SSH connection on Linux/macOS)
  • Terminus Sublime Text package (used for remote terminal feature on Linux/macOS, required on Windows)

On Debian : apt-get install -y sshfs

Installation

With Package Control (recommended)

  1. Open your command palette and type in : Package Control: Install Package
  2. Browse the list or search for SSHubl
  3. Press Enter and you're done !

Package Control dedicated page here.

Manually

  1. Go to the Sublime Text packages folder (usually $HOME/.config/sublime-text/Packages/ or %AppData%\Sublime Text\Packages\)
  2. Clone this repository there : git clone https://github.com/HorlogeSkynet/SSHubl.git
  3. [Linux/macOS] Satisfy either pexpect and ptyprocess third-party dependencies in Sublime Text Lib/python38/ folder (see here for further information) or Terminus Sublime Text package dependency
  4. [Windows] Satisfy Terminus Sublime Text package dependency
  5. Restart Sublime Text and… :tada:

Usage

Open your command palette and type in SSHubl to select Connect to server. Once connected, you will be able to select Forward port/socket, Open/Select directory (mount sshfs) or even Open a terminal commands.

Settings

{
    "debug": false,
    // Custom path to OpenSSH client program
    // /!\ This setting requires plugin reload (or Sublime restart)
    "ssh_path": null,
    // Custom path to `sshfs` FUSE client program
    // /!\ This setting requires plugin reload (or Sublime restart)
    "sshfs_path": null,
    // Custom path to `umount` program (`fusermount` on Linux)
    // /!\ This setting requires plugin reload (or Sublime restart)
    "umount_path": null,
    // Custom options to pass to OpenSSH **master** (e.g. useful for bastion traversal)
    "ssh_options": {
        //"ConnectTimeout": 30,
    },
    // Custom login timeout (for pexpect)
    "ssh_login_timeout": 10,
    // Set to `false` to disable host authentication for loopback addresses (cf. NoHostAuthenticationForLocalhost)
    "ssh_host_authentication_for_localhost": true,
    // Server keepalive interval (as recommended in sshfs documentation)
    "ssh_server_alive_interval": 15,
}

Frequently Asked Questions

Why can I non-interactively connect to new hosts without accepting their fingerprint ?

pexpect package is known to always accept remotes' public key, and it isn't configurable.

How is “SSHubl” pronounced ?

[ʃʌbəl]

Why haven't you opted for a pure Python approach ?

Paramiko doesn't support FUSE. There is also fs.sshfs, but it relies on PyFilesystem 2 which doesn't support “re-exposing” FUSE as local mount point.

Is SSHubl compatible with other SSH clients ?

As it uses OpenSSH connections multiplexing feature, no.

Do you plan to support Sublime Text 3 ?

It's very unlikely as SSHubl requires Python 3.8 runtime and depends on several Sublime Text 4081+ API.