externalprograms

package
v1.13.1 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2026 License: GPL-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyPathMappings

func ApplyPathMappings(path string, mappings []models.PathMapping) string

ApplyPathMappings applies configured path mappings to convert remote paths to local paths.

Mappings are matched longest-prefix-first to handle overlapping prefixes correctly. Prefix matching requires a path separator boundary (/ or \) to avoid false matches like "/data" matching "/data-backup".

func BuildArguments

func BuildArguments(template string, torrentData map[string]string) []string

BuildArguments substitutes variables in the args template with torrent data. Returns arguments as an array suitable for exec.Command (no manual quoting needed).

func SplitArgs

func SplitArgs(s string) []string

SplitArgs splits a command line string into arguments, respecting quoted strings. It strips surrounding single/double quotes from quoted segments.

Types

This section is empty.

Jump to

Keyboard shortcuts

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