name

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2023 License: BSD-2-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidPath = errors.New("the path contains invalid characters")
)

Functions

func Humanize

func Humanize(path string) (string, error)

Humanize deobfuscates the URL path and returns the formatted, human-readable group name. If the URL path contains invalid characters then an error is returned.

func Obfuscate

func Obfuscate(name string) string

Obfuscate formats the named string to be used as a URL path.

Types

type List

type List map[Path]string

List is a map of releasers and their well-known styled names.

func Lower

func Lower() List

Lower returns the list of styled names that use all lowercasing.

func Names

func Names() List

Names returns the list of well-known styled names.

func Special

func Special() List

Special returns the list of styled names that use special mix or all lower or upper casing.

func Upper

func Upper() List

Upper returns the list of styled names that use all uppercasing.

type Path

type Path string

Path is a the URL path of the releaser.

func (Path) String

func (path Path) String() string

String returns the well-known styled name of the releaser if it exists.

func (Path) Valid

func (path Path) Valid() bool

Valid returns true if the URL path uses valid characters. Valid URL paths are all lowercase and contain only alphanumeric characters, dashes, underscores, amperage and asterisks.

Jump to

Keyboard shortcuts

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