utils

package module
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2023 License: MIT Imports: 5 Imported by: 1

README

-utils-go

Standardised utility package

-utils-go is part of the kiss-my-package set used by apps like FaceMasq, PaperBag, Celestial, Executrix, and more

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEnv

func GetEnv(key string) string

func IsDevelopment

func IsDevelopment(strict bool) bool

func IsIntegration

func IsIntegration(strict bool) bool

func IsProduction

func IsProduction(strict bool) bool

func IsStaging

func IsStaging(strict bool) bool

func IsStrFormat

func IsStrFormat(input string) bool

func IsTest

func IsTest() bool

func MustGetEnv

func MustGetEnv(key string) string

func Sha256

func Sha256(message string) string

func TernaryAny

func TernaryAny(comparison bool, isTrue any, isFalse any) any

func TernaryByte

func TernaryByte(comparison bool, isTrue []byte, isFalse []byte) []byte

func TernaryFloat

func TernaryFloat(comparison bool, isTrue float64, isFalse float64) float64

func TernaryInt

func TernaryInt(comparison bool, isTrue int, isFalse int) int

func TernaryInt64

func TernaryInt64(comparison bool, isTrue int64, isFalse int64) int64

func TernaryStr

func TernaryStr(comparison bool, isTrue string, isFalse string) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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