Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HtmlHyperlinkEncode ¶ added in v0.0.6
HtmlHyperlinkEncode takes a string, and a uri and returns an html representation of a hyperlink using the normal anchor tags.
func NamedArgsTemplate ¶ added in v0.0.10
NamedArgsTemplate takes a format string that contains named args wrapped in curly brackets, and templates them in. For example, "hello {name}!" will turn into "hello world!" if you pass a map with "name" => "world" into it.
func ShellHyperlinkEncode ¶
ShellHyperlinkEncode takes a string, and a uri and returns a shell encoded representation of a hyperlink using the modern shell escaping sequence. Idea from: https://purpleidea.com/blog/2018/06/29/hyperlinks-in-gnome-terminal/
func SmartURI ¶
SmartURI returns a "smart" URI given an internal UID that we have. The UID is the special string that's the unique identifier that's returned from each backend. We convert this into a "better" URI if we can. If we can't, we just return the uid unchanged. TODO: the different helper functions that are called within could be provided by each backend, instead of us writing them here and assuming how they work.
Types ¶
This section is empty.
Directories ¶
Path | Synopsis |
---|---|
Package errwrap contains some error helpers.
|
Package errwrap contains some error helpers. |
Package licenses provides some structures for handling and representing software licenses.
|
Package licenses provides some structures for handling and representing software licenses. |
Package safepath implements some types and methods for dealing with POSIX file paths safely.
|
Package safepath implements some types and methods for dealing with POSIX file paths safely. |