Rand Stats

Sys::OsRelease

zef:samy

NAME

Sys::OsRelease - Read OS info from system os-release file

SYNOPSIS

use Sys::OsRelease;

my %osinfo = os-release;

DESCRIPTION

Sys::OsRelease is a module that provides the os-release function, which reads your system's os-release file and returns a hash of the data found in the file.

The os-release file is a text file found on many modern *NIX systems that conveniently details operating system identification data, such as the OS name and version. More information can be found in the official standard by freedesktop.org.

By default, os-release will try to locate and read one of the following files in descending order of priority:

/etc/os-release
/usr/lib/os-release

os-release's signature:

Str  :$path = get_os-release_path(),
Bool :$defaults = False,
Bool :$strict = True,
Bool :$standard-only = True,
--> Hash

AUTHOR

Written by Samuel Young, samyoung12788@gmail.com.

COPYRIGHT

Copyright 2024, Samuel Young

This program is free software; you can redistribute it and/or modify it under the terms of the Artistic License 2.0.

SEE ALSO

os-release