Documentation
¶
Index ¶
- func AmericanStopPanelGlyph() string
- func AutoPager(input interface{}, linesPerPage int) *cerr.CustomError
- func Blue(sentence string) string
- func BlueInfoGlyph() string
- func Center(input string) string
- func ChangeLog(cl string, clear bool)
- func ClearTTY()
- func DecodeString(encodedstring string, privateKey string) string
- func EnabledGlyph() string
- func EncodeString(string2encode string, privateKey string) string
- func ErrorGlyph() string
- func EuropeanStopPanelGlyph() string
- func FatalCollisionGlyph() string
- func FatalSkullBonesGlyph() string
- func GetBoolValFromPrompt(prompt string) bool
- func GetFStype(mountpoint string) (string, *cerr.CustomError)
- func GetIntValFromPrompt(prompt string) int
- func GetPassword(prompt string, debugmode bool) string
- func GetStringSliceFromPrompt(prompt string) []string
- func GetStringValFromPrompt(prompt string) string
- func GetTerminalSize() (int, int)
- func GetValueFromPrompt(prompt string) interface{}
- func Glyph(kind string) string
- func Green(sentence string) string
- func GreenGoGlyph() string
- func GreenOkGlyph() string
- func InfoGlyph() string
- func LightbulbGlyph() string
- func NoteGlyph() string
- func Pager(lines []string, linesPerPage int)
- func PagerFromFile(filePath string, linesPerPage int) *cerr.CustomError
- func PagerFromReader(r io.Reader, linesPerPage int) *cerr.CustomError
- func PagerFromString(text string, linesPerPage int)
- func Red(sentence string) string
- func RedErrorGlyph() string
- func ReverseString(s string) (result string)
- func Right(input string) string
- func SI(nombre interface{}) string
- func ScrollGlyph() string
- func ThumbsDownGlyph() string
- func ThumbsUpGlyph() string
- func TipGlyph() string
- func WarningGlyph() string
- func White(sentence string) string
- func Yellow(sentence string) string
- func YellowTipGlyph() string
- func YellowWarningGlyph() string
- type RepoInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AmericanStopPanelGlyph ¶ added in v2.4.2
func AmericanStopPanelGlyph() string
func AutoPager ¶
func AutoPager(input interface{}, linesPerPage int) *cerr.CustomError
AutoPager dispatches to the appropriate PagerFrom* function based on input type.
func BlueInfoGlyph ¶ added in v2.4.2
func BlueInfoGlyph() string
func DecodeString ¶
func EncodeString ¶
Quick functions to encode and decode strings This is based on my encryption-decryption tool : https://github.com/jeanfrancoisgratton/encdec
func ErrorGlyph ¶ added in v2.4.2
func ErrorGlyph() string
func FatalSkullBonesGlyph ¶ added in v2.4.2
func FatalSkullBonesGlyph() string
func GetBoolValFromPrompt ¶
func GetFStype ¶
func GetFStype(mountpoint string) (string, *cerr.CustomError)
Check which type of filesystem the mountpoint is. Currently only supports MacOS and linux; I've broken my Windows test VM and have no time for it
func GetIntValFromPrompt ¶
func GetPassword ¶
Breaking change: if DebugMode is true, we catch the passwd in cleartext
func GetStringValFromPrompt ¶
Getting typed values from prompt
func GetValueFromPrompt ¶
func GetValueFromPrompt(prompt string) interface{}
This one is more generic in the sense that it should be used whenever We cannot know before run-time what type of value should be expected
func Glyph ¶ added in v2.4.2
Glyph returns the glyph string for a given kind. Supported kinds: "stop-eu", "stop-us", "fatal-collision", "fatal-skull", "go", "error", "info", "note", "scroll", "tip", "lightbulb", "thumbs-up", "thumbs-down".
func GreenOkGlyph ¶ added in v2.4.2
func GreenOkGlyph() string
func LightbulbGlyph ¶ added in v2.4.2
func LightbulbGlyph() string
func PagerFromFile ¶
func PagerFromFile(filePath string, linesPerPage int) *cerr.CustomError
PagerFromFile reads a file and pages its content.
func PagerFromReader ¶
func PagerFromReader(r io.Reader, linesPerPage int) *cerr.CustomError
PagerFromReader reads from an io.Reader and pages its content.
func PagerFromString ¶
PagerFromString splits a full string into lines, then pages it.
func RedErrorGlyph ¶ added in v2.4.2
func RedErrorGlyph() string
func ReverseString ¶
This function takes a string and returns its reverse Thus, "12345" becomes "54321"
func SI ¶
func SI(nombre interface{}) string
This function was originally written in 1993, in C, by my friend Jean-François Gauthier (jief@brebis.dyndns.org) I've ported it in C# in 2011. It still loosely based on J.F.Gauthier's version, somehow; credit is given where credit is due This function transforms a multi-digit number in International Notation; 1234567 thus becomes 1,234,567
func ScrollGlyph ¶ added in v2.4.2
func ScrollGlyph() string
func ThumbsDownGlyph ¶ added in v2.4.2
func ThumbsDownGlyph() string
func ThumbsUpGlyph ¶ added in v2.4.2
func ThumbsUpGlyph() string
func WarningGlyph ¶ added in v2.4.1
func WarningGlyph() string
func YellowTipGlyph ¶ added in v2.4.2
func YellowTipGlyph() string
func YellowWarningGlyph ¶ added in v2.4.2
func YellowWarningGlyph() string
Types ¶
type RepoInfo ¶
type RepoInfo struct { Scheme string // e.g., https, ssh ("" if unknown) Host string // e.g., git.example.com Port string // optional (if included in the URL) TopLevelOwner string // e.g., group or username FullOwnerPath string // e.g., group/subgroup Repo string // e.g., repo (no .git) RawURL string // original input, for debug }
func ExtractRepoInfo ¶
ExtractRepoInfo: extracts various info from the URL or SSH-style URL Returns an error if the URL is invalid or if the repo name is missing
Source Files
¶
Directories
¶
Path | Synopsis |
---|---|
logging/logger.go helperFunctions - logging subpackage Refactor: Aug 13, 2025 (USER outside severity ladder) File: logging/logger.go
|
logging/logger.go helperFunctions - logging subpackage Refactor: Aug 13, 2025 (USER outside severity ladder) File: logging/logger.go |