package License::SPDX;
use strict;
use warnings;
use Class::Utils qw(set_params);
use Cpanel::JSON::XS;
use Error::Pure qw(err);
use File::Share ':all';
use List::Util qw(first);
use Perl6::Slurp qw
ses.
open my $data_fh, '<', dist_dir('License-SPDX').'/licenses.json';
my $data = slurp($data_fh);
$self->{'licenses'} = Cpanel::JSON::XS->new->ascii->pretty->allow_nonref->decode($data);
# Load
my $data_exc_fh, '<', dist_dir('License-SPDX').'/exceptions.json';
my $data_exc = slurp($data_exc_fh);
$self->{'exceptions'} = Cpanel::JSON::XS->new->ascii->pretty->allow_nonref->decode($data_exc);