https://github.com/duruyao/goshare
GoShare provides a simple Web UI and a file transfer service which using HTTP protocol.
https://github.com/duruyao/goshare
cross-platform go golang http share-file
Last synced: 25 days ago
JSON representation
GoShare provides a simple Web UI and a file transfer service which using HTTP protocol.
- Host: GitHub
- URL: https://github.com/duruyao/goshare
- Owner: duruyao
- License: apache-2.0
- Created: 2021-11-16T04:46:42.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2024-07-29T08:47:22.000Z (over 1 year ago)
- Last Synced: 2025-09-02T11:58:07.023Z (5 months ago)
- Topics: cross-platform, go, golang, http, share-file
- Language: Go
- Homepage:
- Size: 190 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# GoShare
GoShare provides a simple Web UI and a file transfer service which using HTTP protocol.
## Install
### Download executable
Download the compiled **[releases](https://github.com/duruyao/goshare/releases)** for your platform.
## Usage
Type `goshare -h` to show help manual.
```text
_____ _____ _
/ ____| / ____| |
| | __ ___| (___ | |__ __ _ _ __ ___
| | |_ |/ _ \\___ \| '_ \ / _' | '__/ _ \
| |__| | (_) |___) | | | | (_| | | | __/
\_____|\___/_____/|_| |_|\__,_|_| \___|
Usage: goshare [OPTIONS]
GoShare shares files and directories via HTTP protocol
Options:
-h, --help Display this help message
--host STRING Host address to listen (default: '0.0.0.0:80')
--path STRING Path or directory (default: '${PWD}')
--scheme STRING Scheme name (default: 'http')
--url-prefix STRING Custom URL prefix (default: '/')
-v, --version Print version information and quit
Examples:
./goshare -host 0.0.0.0:80 -path ${PWD}
./goshare --host 0.0.0.0:80 --path ${PWD} --url-prefix /
./goshare --host=0.0.0.0:80 --path=${PWD} --url-prefix=/
See more about GoShare at https://github.com/duruyao/goshare
```
Start goshare in the foreground.
```bash
sudo goshare --host=localhost:3927 --url-prefix=$PWD --path=$PWD
```
Start goshare in the background.
```bash
sudo goshare --host=localhost:3927 --url-prefix=$PWD --path=$PWD &
```
Start goshare in the background via **Nohup**.
```bash
sudo nohup goshare --host=localhost:3927 --url-prefix=$PWD --path=$PWD /tmp/goshare.out 2>&1 &
```
Share the files with your group members by using the **LAN IP** or **WAN IP** instead of `localhost`, `127.0.0.1`, `*` or `0.0.0.0`.
Browse the file system via a web browser.

Download files via `wget` or `curl`.
```bash
wget
curl -o
```
Download the directories via `wget`.
```bash
wget -r -np -nH -R "index.html*"
```