format

package
v0.0.0-...-0798a42 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddressForHumans

func AddressForHumans(a *mail.Address) string

AddressForHumans formats the address. Meant for display purposes to the humans, not for sending over the wire.

func CompactPath

func CompactPath(name string, sep rune) (compact string)

CompactPath reduces a directory path into a compact form. The directory name will be split with the provided separator and each part will be reduced to the first letter in its name: INBOX/01_WORK/PROJECT will become I/W/PROJECT.

func DummyIfZeroDate

func DummyIfZeroDate(date time.Time, format string, todayFormat string,
	thisWeekFormat string, thisYearFormat string,
) string

func FormatAddresses

func FormatAddresses(l []*mail.Address) string

FormatAddresses formats a list of addresses into a human readable string

Types

This section is empty.

Jump to

Keyboard shortcuts

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