deeplink

package
v0.7.201 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2026 License: AGPL-3.0, AGPL-3.0-or-later Imports: 11 Imported by: 0

Documentation

Overview

Package deeplink parses warpnet:// URLs and registers the scheme per OS.

Index

Constants

View Source
const Scheme = "warpnet"

Variables

View Source
var ErrMissingID = errors.New("deeplink: missing resource id")
View Source
var ErrNotWarpnetURL = errors.New("deeplink: not a warpnet:// URL")
View Source
var ErrUnsupportedKind = errors.New("deeplink: unsupported resource kind")

Functions

func Register

func Register() error

Register claims warpnet:// for this binary. Best-effort; idempotent.

Types

type Kind

type Kind string
const (
	KindUser Kind = "user"
)
type Link struct {
	Kind Kind
	ID   string
	Raw  string
}

func FromArgs

func FromArgs(args []string) (Link, bool)

FromArgs returns the first parseable warpnet:// arg, tolerating leading "-"/"--".

func Parse

func Parse(raw string) (Link, error)

Jump to

Keyboard shortcuts

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