Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/spectre10/fs-cli
WebRTC based P2P multi-threaded filesharing CLI app written in Golang.
https://github.com/spectre10/fs-cli
cli cli-app cobra-cli file-sharing go golang hacktoberfest multithreading p2p p2pshare peer-to-peer webrtc
Last synced: about 19 hours ago
JSON representation
WebRTC based P2P multi-threaded filesharing CLI app written in Golang.
- Host: GitHub
- URL: https://github.com/spectre10/fs-cli
- Owner: spectre10
- License: apache-2.0
- Created: 2023-05-24T20:48:03.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-12T05:41:18.000Z (about 1 month ago)
- Last Synced: 2024-12-12T06:28:29.977Z (about 1 month ago)
- Topics: cli, cli-app, cobra-cli, file-sharing, go, golang, hacktoberfest, multithreading, p2p, p2pshare, peer-to-peer, webrtc
- Language: Go
- Homepage:
- Size: 129 KB
- Stars: 26
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[![Go Reference](https://pkg.go.dev/badge/github.com/spectre10/fs-cli.svg)](https://pkg.go.dev/github.com/spectre10/fs-cli)
[![Go Report Card](https://goreportcard.com/badge/github.com/spectre10/fileshare-cli)](https://goreportcard.com/report/github.com/spectre10/fileshare-cli)# fs-cli
fs-cli is multi-threaded CLI app written in Golang to transfer multiple files concurrently via WebRTC.
It is peer-to-peer (P2P), so there are no servers in middle. However, Google's STUN server is used to retrieve information about public address and the type of NAT clients are behind. (Transfer of files does not happen through Google servers.)
This information is used to setup a Peer Connection between clients. After connecting, each file is assigned a WebRTC Data-Channel for streaming. And the transfer happens concurrently over all Data-Channels.
You can also find your public IP address via WebRTC. (See Usage Below)
https://github.com/spectre10/fs-cli/assets/72698233/fab8633b-af72-420c-9eff-3f91ada0eabc
Currently only tested on Linux.
## Architecture
![WebRTC](https://github.com/spectre10/fs-cli/assets/72698233/4c488af3-61e5-4e5f-9dc0-c5dfe528284e)
## Installation
If you have Go installed, ([Install from here](https://go.dev/doc/install))
Add $GOPATH/bin to your $PATH. And then,
if you want the latest release version, then run this command,
```sh
go install github.com/spectre10/fs-cli@latest
```
orif you want a specific release version, then run this command,
```sh
go install github.com/spectre10/[email protected]
```
***Alternatively, you can also download from GitHub Releases.
## Usage
To send a file,
```
fs-cli send ...
```To receive a file,
```
fs-cli receive
```To find your IP address,
```
fs-cli findip
```## Future Steps
* (**On-going**) Add a web UI which can be hosted locally. (Single Binary.)
-----------------------------------
## References
* [pion/webrtc](https://github.com/pion/webrtc)
* [Antonito/gfile](https://github.com/Antonito/gfile)