util

package
v0.0.0-...-d79ae21 Latest Latest
Warning

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

Go to latest
Published: May 6, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Choice

func Choice[T any](S []T) T

func RandInt

func RandInt(i, j int) int

i = max, j = min

func RemoveByIndex

func RemoveByIndex[S any](slice []S, i int) ([]S, error)

Types

type OSType

type OSType int
const (
	Windows OSType = iota
	Linux
	MacOS
	OpenBSD
	FreeBSD
	UnknownOS
)

func GetRuntimeOS

func GetRuntimeOS() (ostype OSType)

func (OSType) String

func (t OSType) String() string

func (OSType) Unix

func (t OSType) Unix() bool

Jump to

Keyboard shortcuts

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