App-skos2jskos

 view release on metacpan or  search on metacpan

script/skos2jskos  view on Meta::CPAN

die "output directory not found: " . $opt{directory} . "\n"
  unless -d $opt{directory};

$opt{language} //= 'en';
$opt{verbose} = 2 if $opt{debug};

## Logging methods
use Term::ANSIColor;
my $colored = -t STDOUT;    ## no critic

sub error($) {              ## no critic
    say STDERR ( $colored ? colored( $_[0], 'red' ) : $_[0] );
}

sub fatal($) {              ## no critic
    error $_[0];
    exit 1;
}

sub warning($) {            ## no critic
    say STDERR ( $colored ? colored( $_[0], 'yellow' ) : $_[0] );
}

sub info($) {               ## no critic
    return if $opt{quiet};
    say( $colored ? colored( $_[0], 'green' ) : $_[0] );
}

sub debug($) {              ## no critic
    return unless $opt{verbose};
    say( $colored ? colored( $_[0], 'white' ) : $_[0] );
}

sub trace($) {              ## no critic
    return unless $opt{verbose} > 1;
    say $_[0];
}

## check where to get RDF data from
use RDF::Trine;
use RDF::Query;
use RDF::Query::Client;

my $source = $opt{sparql} || RDF::Trine::Model->new;



( run in 0.914 second using v1.01-cache-2.11-cpan-65fba6d93b7 )