Unix and Linux Discussions Tagged with slackware |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
20 |
39,075 |
Fedora |
|
|
|
0 |
2,485 |
UNIX for Beginners Questions & Answers |
|
|
|
3 |
15,402 |
Slackware |
|
|
|
7 |
67,201 |
IP Networking |
|
|
|
8 |
15,481 |
Slackware |
|
|
|
2 |
11,637 |
Slackware |
|
|
|
0 |
9,571 |
Slackware |
|
|
|
0 |
4,279 |
Slackware |
|
|
|
2 |
4,137 |
UNIX for Dummies Questions & Answers |
|
|
|
0 |
1,121 |
Security Advisories (RSS) |
|
|
|
0 |
1,550 |
Software Releases - RSS News |
|
|
|
0 |
1,719 |
UNIX and Linux RSS News |
|
|
|
0 |
1,328 |
Security Advisories (RSS) |
|
|
|
0 |
1,294 |
Security Advisories (RSS) |
|
|
|
0 |
1,462 |
Security Advisories (RSS) |
|
|
|
0 |
2,025 |
UNIX and Linux RSS News |
|
|
|
0 |
1,540 |
Security Advisories (RSS) |
|
|
|
0 |
967 |
Software Releases - RSS News |
|
|
|
0 |
1,572 |
Security Advisories (RSS) |
|
|
|
0 |
1,633 |
Security Advisories (RSS) |
|
|
|
0 |
1,348 |
Security Advisories (RSS) |
|
|
|
0 |
2,064 |
Security Advisories (RSS) |
|
|
|
0 |
1,599 |
Security Advisories (RSS) |
|
|
|
0 |
1,686 |
UNIX and Linux RSS News |
|
|
|
0 |
1,381 |
Security Advisories (RSS) |
|
|
|
0 |
1,334 |
Software Releases - RSS News |
|
|
|
0 |
1,181 |
Software Releases - RSS News |
|
|
|
0 |
1,984 |
Security Advisories (RSS) |
|
|
|
0 |
1,487 |
Security Advisories (RSS) |
|
|
|
0 |
1,426 |
UNIX and Linux RSS News |
|
|
|
0 |
1,894 |
Security Advisories (RSS) |
|
|
|
0 |
1,599 |
UNIX and Linux RSS News |
|
|
|
0 |
1,594 |
Security Advisories (RSS) |
|
|
|
0 |
3,033 |
Security Advisories (RSS) |
|
|
|
1 |
2,789 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
4,467 |
Filesystems, Disks and Memory |
|
|
|
6 |
42,399 |
UNIX for Dummies Questions & Answers |
|
|
|
10 |
26,872 |
Cybersecurity |
|
|
|
2 |
5,769 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
4,028 |
IP Networking |
Linux::Distribution(3pm) User Contributed Perl Documentation Linux::Distribution(3pm)
NAME
Linux::Distribution - Perl extension to detect on which Linux distribution we are running.
SYNOPSIS
use Linux::Distribution qw(distribution_name distribution_version);
if(my $distro = distribution_name) {
my $version = distribution_version();
print "you are running $distro, version $version
";
} else {
print "distribution unknown
";
}
Or else do it OO:
use Linux::Distribution qw(distribution_name distribution_version);
my $linux = Linux::Distribution->new;
if(my $distro = $linux->distribution_name()) {
my $version = $linux->distribution_version();
print "you are running $distro, version $version
";
} else {
print "distribution unknown
";
}
DESCRIPTION
This is a simple module that tries to guess on what linux distribution we are running by looking for release's files in /etc. It now looks
for 'lsb-release' first as that should be the most correct and adds ubuntu support. Secondly, it will look for the distro specific files.
It currently recognizes slackware, debian, suse, fedora, redhat, turbolinux, yellowdog, knoppix, mandrake, conectiva, immunix, tinysofa,
va-linux, trustix, adamantix, yoper, arch-linux, libranet, gentoo, ubuntu, scientific, oracle enterprise linux and redflag.
It has function to get the version for debian, suse, fedora, redhat, gentoo, slackware, scientific, oracle enterprise linux, redflag and
ubuntu(lsb). People running unsupported distro's are greatly encouraged to submit patches :-)
EXPORT
None by default.
TODO
Add the capability of recognize the version of the distribution for all recognized distributions.
AUTHORS
Alexandr Ciornii <alexchorny@gmail.com>, <http://chorny.net> Alberto Re, <alberto@accidia.net> Judith Lebzelter, <judith@osdl.org>
COPYRIGHT AND LICENSE
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.5 or,
at your option, any later version of Perl 5 you may have available.
perl v5.14.2 2012-03-18 Linux::Distribution(3pm)