NAME

App::ansipic - show images in the terminal as lines of text

SYNOPSIS

use App::ansipic qw(ansipic);
my $status = ansipic('-w', '2/', 'logo.png');

use Command::Run;
my $out = Command::Run->new(
    command => [ \&App::ansipic::ansipic, 'logo.png' ],
    nofork  => 1,
)->run->{data};

DESCRIPTION

The command ansipic as a function. ansipic takes the arguments of the command, prints the rows of the images to the standard output, and returns the status: 0, 1 when a file is not shown, and 2 for an error. It does not exit, even for --help and --version. Command::Run does not take the value: the status of a function it runs is 0, unless the function dies.

SEE ALSO

ansipic, Text::ANSI::Image, Command::Run

AUTHOR

Kazumasa Utashiro

LICENSE

Copyright © 2026 Kazumasa Utashiro.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.