| 1 | package Devel::AssertOS::Linux::RealDebian; | ||||||||||||||||||||||||||||
| 2 | |||||||||||||||||||||||||||||
| 3 | 3 | ▶ | use Devel::CheckOS; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 4 | 3 | ▶ | use strict; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 5 | 3 | ▶ | use warnings; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 6 | 3 | ▶ | no warnings 'redefine'; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 7 | |||||||||||||||||||||||||||||
| 8 | 3 | ▶ | use Devel::CheckOS::Helpers::LinuxOSrelease 'distributor_id'; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 9 | |||||||||||||||||||||||||||||
| 10 | our $VERSION = '1.1'; | ||||||||||||||||||||||||||||
| 11 | |||||||||||||||||||||||||||||
| 12 | 10 | ▶ | sub os_is { | ||||||||||||||||||||||||||
|
Subroutine
os_is: called CC=3 SCAR=13.1
| |||||||||||||||||||||||||||||
| 13 | 10 | my $id = distributor_id; | |||||||||||||||||||||||||||
| 14 | |||||||||||||||||||||||||||||
| 15 | 10 | ▶ | Devel::CheckOS::os_is('Linux') && | ||||||||||||||||||||||||||
|
Branch: 1 branch
Condition33%1/3
Devel::CheckOS::os_is("Linux") and defined $id
MC/DC0%0/2
Devel::CheckOS::os_is("Linux") and defined $id
Devel::CheckOS::os_is("Linux")
defined $id
Truth table33%1/3
A and B
A= Devel::CheckOS::os_is("Linux")B= defined $id
| |||||||||||||||||||||||||||||
| 16 | defined($id) && | ||||||||||||||||||||||||||||
| 17 | $id eq 'debian'; | ||||||||||||||||||||||||||||
| 18 | } | ||||||||||||||||||||||||||||
| 19 | |||||||||||||||||||||||||||||
| 20 | 0 | ▶ | sub expn { "The Linux distribution is real Debian, recent enough to have \`/etc/os-release\`, and not some Debian derivative" } | ||||||||||||||||||||||||||
|
Subroutine
expn: not called CC=1 SCAR=6.9
| |||||||||||||||||||||||||||||
| 21 | |||||||||||||||||||||||||||||
| 22 | Devel::CheckOS::die_unsupported() unless(os_is()); | ||||||||||||||||||||||||||||
| 23 | |||||||||||||||||||||||||||||
| 24 | =head1 COPYRIGHT and LICENCE | ||||||||||||||||||||||||||||
| 25 | |||||||||||||||||||||||||||||
| 26 | Copyright 2024 David Cantrell | ||||||||||||||||||||||||||||
| 27 | |||||||||||||||||||||||||||||
| 28 | This software is free-as-in-speech software, and may be used, distributed, and modified under the terms of either the GNU General Public Licence version 2 or the Artistic Licence. It's up to you which one you use. The full text of the licences can be found in the files GPL2.txt and ARTISTIC.txt, respectively. | ||||||||||||||||||||||||||||
| 29 | |||||||||||||||||||||||||||||
| 30 | =cut | ||||||||||||||||||||||||||||
| 31 | |||||||||||||||||||||||||||||
| 32 | 1; | ||||||||||||||||||||||||||||
| 33 | |||||||||||||||||||||||||||||