outplayer

package
v0.3.22 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 15, 2026 License: MIT Imports: 15 Imported by: 0

Documentation

Overview

Package outplayer uploads media files to Outplayer's "Wi-Fi transfer" feature.

Outplayer (an iOS media player) exposes a GCDWebUploader HTTP server when Wi-Fi transfer is enabled. It accepts multipart form uploads at POST /upload (form fields: "path" for the destination directory and "files[]" for the file) and lists directories at GET /list?path=/.

Unlike the gowebdav transfer path, the source media lives on an rclone remote rather than local disk, so uploads are streamed: `rclone cat <remote>` is piped straight into a chunked multipart POST without staging the file on local disk. GCDWebUploader accepts a chunked (unknown Content-Length) body, so the exact file size is never required.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NormalizeDir

func NormalizeDir(dir string) string

NormalizeDir converts a user-supplied folder into the "path" form Outplayer expects: a leading and trailing slash, with the root represented as "/".

func Reachable

func Reachable(ctx context.Context, baseURL string) error

Reachable verifies that an Outplayer target is responding by requesting a directory listing. It returns a descriptive error when the target cannot be reached, so callers can fail fast before starting a large upload.

func Upload

func Upload(ctx context.Context, rclonePaths []string, baseURL, dir, rcloneBinary string) error

Upload streams each rclone remote file to the Outplayer target sequentially, displaying the same Bubble Tea progress UI used by downloads and WebDAV uploads. baseURL is the target root (e.g. "http://192.168.0.34"), dir is the destination folder ("" = root), and rcloneBinary defaults to "rclone". A failed file does not stop the remaining uploads; the first error encountered is returned.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL