distro

package module
v0.0.0-...-476ea88 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: MIT Imports: 6 Imported by: 2

README

Go-Distro

This is a library to get the OS, its version, and its codename in Golang.

Currently, only the OS I am using is supported.

I think this liblary has generic structure, so it would be helpful if you could add distribution-specific code.

License

You can choose whichever you prefer.

Sample tool

You can chck your local environment with following command.

go run ./cmd/main.go

Special Thanks

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Arch       base.ID = linux.Arch.ID()
	Debian     base.ID = linux.Debian.ID()
	Ubuntu     base.ID = linux.Ubuntu.ID()
	OtherLinux base.ID = linux.Other.ID()
)

Linux

View Source
var DarwinList = &darwin.VersionList
View Source
var LinuxList = &linux.DistroList

Support list

View Source
var Other = base.Other.ID()

Other

Functions

func GetDetail

func GetDetail() base.OS

func GetOS

func GetOS() base.ID

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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