🚧 (Alpha stage software) Library and tooling that supports remote filesystem and process operations. 🚧
Go to file
2022-06-06 18:38:46 -05:00
.github/workflows Add --ssh-backend support to cli and bump to 0.16.3 2022-05-29 15:16:35 -05:00
distant-core Fix watch tests for linux & bump dependency versions (#104) 2022-06-04 17:01:47 -05:00
distant-ssh2 Bump to 0.16.4 and fix #80 and fix #102 2022-06-01 15:35:29 -05:00
src Bump to 0.16.4 and fix #80 and fix #102 2022-06-01 15:35:29 -05:00
tests Fix watch tests for linux & bump dependency versions (#104) 2022-06-04 17:01:47 -05:00
.gitignore Add native ssh (#57) 2021-09-28 00:04:26 -05:00
BUILDING.md Minor documentation changes and update dockerfile to build from source 2022-06-06 18:38:46 -05:00
Cargo.lock Fix watch tests for linux & bump dependency versions (#104) 2022-06-04 17:01:47 -05:00
Cargo.toml Fix watch tests for linux & bump dependency versions (#104) 2022-06-04 17:01:47 -05:00
CHANGELOG.md Minor documentation changes and update dockerfile to build from source 2022-06-06 18:38:46 -05:00
Dockerfile Minor documentation changes and update dockerfile to build from source 2022-06-06 18:38:46 -05:00
README.md Add filesystem watching & remove distant-lua (#102) 2022-03-30 19:32:20 -05:00

distant - remotely edit files and run programs

Crates.io Docs.rs RustC 1.51+

Operating System Status
MacOS (x86, ARM) MacOS CI
Linux (x86) Linux CI
Windows (x86) Windows CI

🚧 (Alpha stage software) This program is in rapid development and may break or change frequently! 🚧

Details

The distant binary supplies both a server and client component as well as a command to start a server and configure the local client to be able to talk to the server.

Additionally, the core of the distant client and server codebase can be pulled in to be used with your own Rust crates via the distant-core crate.

Installation

Prebuilt Binaries

If you would like a pre-built binary, check out the releases section.

Building from Source

If you have cargo installed, you can directly download and build the source via:

cargo install distant

Alternatively, you can clone this repository and build from source following the build guide.

Examples

Launch a remote instance of distant. Calling launch will do the following:

  1. Ssh into the specified host (in the below example, my.example.com)
  2. Execute distant listen --host ssh on the remote machine
  3. Receive on the local machine the credentials needed to connect to the server
  4. Depending on the options specified, print/store/use the session settings so future calls to distant action can connect
# Connects to my.example.com on port 22 via SSH to start a new session
# and print out information to configure your system to talk to it
distant launch my.example.com

# NOTE: If you are using sh, bash, or zsh, you can automatically set the
        appropriate environment variables using the following
eval "$(distant launch my.example.com)"

# After the session is established, you can perform different operations
# on the remote machine via `distant action {command} [args]`
distant action copy path/to/file new/path/to/file
distant action spawn -- echo 'Hello, this is from the other side'

License

This project is licensed under either of

Apache License, Version 2.0, (LICENSE-APACHE or apache-license) MIT license (LICENSE-MIT or mit-license) at your option.