Go to file
ChristianVisintin 29f7e3c759 0.1.2
2020-12-13 20:42:20 +01:00
.github Added clippy to workflows 2020-12-12 12:17:33 +01:00
assets/images 0.1.2 2020-12-13 20:42:20 +01:00
dist Dist deb, rpm 2020-12-06 12:32:53 +01:00
docs/drawio Working on AuthActivity 2020-11-21 21:26:27 +01:00
src Optimized performance for file transfer 2020-12-13 11:43:04 +01:00
.gitignore Dist deb, rpm 2020-12-06 12:32:53 +01:00
Cargo.lock Working on 0.1.2 2020-12-12 10:06:11 +01:00
Cargo.toml Optimized code and performance using clippy 2020-12-12 12:14:51 +01:00
CHANGELOG.md Selected file has now colourful background, instead of foreground, for a better readability 2020-12-13 09:55:16 +01:00
CODE_OF_CONDUCT.md Project initialized 2020-11-07 17:48:41 +01:00
CONTRIBUTING.md Contributing guide ok 2020-12-06 22:35:56 +01:00
LICENSE Project initialized 2020-11-07 17:48:41 +01:00
README.md README 2020-12-13 10:25:22 +01:00

TermSCP

License: GPL v3 Stars Issues Downloads Crates.io Docs

Build Build Build

~ Basically, WinSCP on a terminal ~
Developed by Christian Visintin
Current version: 0.1.2 (13/12/2020)



About TermSCP 🖥

TermSCP is basically a porting of WinSCP to terminal. So basically is a terminal utility with an TUI to connect to a remote server to retrieve and upload files and to interact with the local file system. It works both on Linux, MacOS, BSD and Windows and supports SFTP, SCP, FTP and FTPS.

Explorer


Why TermSCP 🤔

It happens quite often to me, when using SCP at work to forget the path of a file on a remote machine, which forces me then to connect through SSH, gather the file path and finally download it through SCP. I could use WinSCP, but I use Linux and I pratically use the terminal for everything, so I wanted something like WinSCP on my terminal. Yeah, I know there midnight commander too, but actually I don't like it very much tbh (and hasn't a decent support for scp).

Features 🎁

  • Different communication protocols
    • SFTP
    • SCP
    • FTP and FTPS
  • Practical user interface to explore and operate on the remote and on the local machine file system
  • Compatible with Windows, Linux, BSD and MacOS
  • Written in Rust
  • Easy to extend with new file transfers protocols

Installation 🛠

If you're considering to install TermSCP I want to thank you 💛 ! I hope you will enjoy TermSCP!
If you want to contribute to this project, don't forget to check out our contribute guide. Read More

Cargo 🦀

# Install termscp through cargo
cargo install termscp

Deb package 📦

Get deb package from HERE or run wget https://github.com/ChristianVisintin/TermSCP/releases/download/latest/termscp_0.1.2_amd64.deb

then install through dpkg:

dpkg -i termscp_*.deb
# Or even better with gdebi
gdebi termscp_*.deb

RPM package 📦

Get rpm package from HERE or run wget https://github.com/ChristianVisintin/TermSCP/releases/download/latest/termscp-0.1.2-1.x86_64.rpm

then install through rpm:

rpm -U termscp_*.rpm

Chocolatey 🍫

You can install TermSCP on Windows using chocolatey

Start PowerShell as administrator and run

choco install termscp

Alternatively you can download the ZIP file from HERE

and then with PowerShell started with administrator previleges, run:

choco install termscp -s .

Brew 🍻

You can install TermSCP on MacOS using brew

From your terminal run

brew tap ChristianVisintin/termscp
brew install termscp

Usage

TermSCP can be started with the following options:

  • -P, --password <password> if address is provided, password will be this argument
  • -v, --version Print version info
  • -h, --help Print help page

TermSCP can be started in two different mode, if no extra arguments is provided, TermSCP will show the authentication form, where the user will be able to provide the parameters required to connect to the remote peer.

Alternatively, the user can provide an address as argument to skip the authentication form and starting directly the connection to the remote server.

Address argument

The address argument has the following syntax:

[protocol]://[username@]<address>[:port]

Let's see some example of this particular syntax, since it's very comfortable and you'll probably going to use this instead of the other one...

  • Connect using default protocol (sftp) to 192.168.1.31, port is default for this protocol (22); username is current user's name

    termscp 192.168.1.31
    
  • Connect using default protocol (sftp) to 192.168.1.31, port is default for this protocol (22); username is root

    termscp root@192.168.1.31
    
  • Connect using scp to 192.168.1.31, port is 4022; username is omar

    termscp scp://omar@192.168.1.31:4022
    

How Password can be provided

You have probably noticed, that, when providing the address as argument, there's no way to provide the password. Password can be basically provided through 3 ways when address argument is provided:

  • -P, --password option: just use this CLI option providing the password. I strongly unrecommend this method, since it's very unsecure (since you might keep the password in the shell history)
  • Via sshpass: you can provide password via sshpass, e.g. sshpass -f ~/.ssh/topsecret.key termscp cvisintin@192.168.1.31
  • You will be prompted for it: if you don't use any of the previous methods, you will be prompted for the password, as happens with the more classics tools such as scp, ssh, etc.

Keybindings ⌨

Key Command
<ESC> Disconnect from remote; return to authentication page
<TAB> Switch between log tab and explorer
<BACKSPACE> Go to previous directory in stack
<RIGHT> Move to remote explorer tab
<LEFT> Move to local explorer tab
<UP> Move up in selected list
<DOWN> Move down in selected list
<PGUP> Move up in selected list by 8 rows
<PGDOWN> Move down in selected list by 8 rows
<ENTER> Enter directory
<SPACE> Upload / download selected file
<D> Make directory
<E> Delete file (Same as CANC)
<G> Go to supplied path
<H> Show help
<I> Show info about selected file or directory
<Q> Quit TermSCP
<R> Rename file
<U> Go to parent directory
<DEL> Delete file
CTRL+C Abort file transfer process

Documentation 📚

The developer documentation can be found on Rust Docs at https://docs.rs/termscp


Known issues 🧻

  • Ftp:
    • Time in explorer is 1 Jan 1970, but shouldn't be: that's because chrono can't parse date in a different locale. So if your server has a locale different from the one on your machine, it won't be able to parse the date.
    • Some servers don't work: yes, some kind of ftp server don't work correctly, sometimes it won't display any files in the directories, some other times uploading files will fail. Up to date, vsftpd is the only one server which I saw working correctly with TermSCP. Am I going to solve this? I'd like to, but it's not my fault at all. Unfortunately rust-ftp is an abandoned project (up to 2020), indeed I had to patch many stuff by myself. I'll try to solve these issues, but it will take a long time.
  • Sftp:
    • sftp is much slower than scp: Okay this is an annoying issue, and again: not my fault. It seems there is an issue with ssh2-rs library. If you want to stay up to date with the status of this issue, subscribe to this issue
  • NoSuchFileOrDirectory on connect: let me guess, you're running on WSL and you've installed termscp through cargo. I know about this issue and it's a glitch of WSL I guess. Don't worry about it, just move the termscp executable into another PATH location, such as /usr/bin.

Upcoming Features 🧪

  • Text viewer: possibility to open and read file both on remote and on local host; this will also support syntax highlighting.

Contributions 🤝🏻

Contributions are welcome! 😉

If you think you can contribute to TermSCP, please follow TermSCP's contributions guide

Changelog

View TermSCP's changelog HERE


Powered by 🚀

TermSCP is powered by these aweseome projects:


Auth


License 📃

Licensed under the GNU GPLv3 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.gnu.org/licenses/gpl-3.0.txt

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

You can read the entire license HERE