Add src/SIMPLE-SEND.md

This commit is contained in:
colin 2024-10-01 10:37:31 -04:00
parent ef5bc53093
commit a4cfe56dc7
1 changed files with 30 additions and 0 deletions

30
src/SIMPLE-SEND.md Normal file
View File

@ -0,0 +1,30 @@
# send
## Overview
The `send` function allows for securely uploading files or piped data to the Firefox Send-compatible server at `https://send.aenow.fun`. A random password is generated for each upload, and the upload has a default expiration of 7 days.
## Usage
### Upload a File
```bash
send <file>
```
### Upload Piped Data
```bash
echo "some data" | send
```
## Environment Variables
- `FFSEND_URL`: URL to download the `ffsend` binary. Default: `https://github.com/timvisee/ffsend/releases/download/v0.2.76/ffsend-v0.2.76-linux-x64`
- `FFSEND_DIR`: Directory to store the `ffsend` binary. Default: `$HOME/.local/bin`
- `FFSEND_PATH`: Full path to the `ffsend` binary. Default: `$FFSEND_DIR/ffsend`
- `DEFAULT_FFSEND_HOST`: Host URL for uploading files. Default: `https://send.aenow.fun`
- `FFSEND_CUSTOM_HOST`: Custom host URL for uploading files. Overrides `DEFAULT_FFSEND_HOST`.
## Installation
The function will automatically install the `ffsend` binary if it is not present. The binary is downloaded from:
```
https://github.com/timvisee/ffsend/releases/download/v0.2.76/ffsend-v0.2.76-linux-x64
```