view release on metacpan or search on metacpan
script/json2json view on Meta::CPAN
#use DD; print "to=$to\n"; dd \%Opts;
} # GET_OPTIONS
my $code_from;
PARSE_INPUT: {
undef $/;
if ($from =~ /\A(perl|perlcolor)\z/) {
if ($Opts{safe}) {
require Data::Undump;
$code_from = 'Data::Undump::undump(scalar <>)';
script/json2json view on Meta::CPAN
require YAML::Syck; $YAML::Syck::ImplicitTyping = 1;
$code_from = 'YAML::Syck::Load(scalar <>)';
} else {
die "serializeutils-convert: Can't convert from '$from'\n";
}
} # PARSE_INPUT
my $code_to;
OUTPUT: {
if ($to =~ /\A(perl|perlcolor)\z/) {
if ($Opts{dumper} eq 'Data::Dump::Color') {
require Data::Dump::Color;
$code_to = "Data::Dump::Color::dump($code_from)";
} elsif ($Opts{dumper} eq 'Data::Dump') {
script/json2json view on Meta::CPAN
die "serializeutils-convert: Can't convert to '$to'\n";
}
eval "print $code_to"; ## no critic: BuiltinFunctions::ProhibitStringyEval
die if $@;
} # OUTPUT
# ABSTRACT: Convert between serialization formats
# PODNAME: json2json
__END__
script/json2json view on Meta::CPAN
=head1 SYNOPSIS
Usage:
% serializeutils-convert [OPTIONS] < INPUT-FILE
For example, when called as C<json2yaml>:
% script-that-outputs-json | json2yaml
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Sets/Sort.pm view on Meta::CPAN
my ($records) = @_;
my $tfh = tempfile(UNLINK => 1);
my $previous;
for my $item (sort @$records) {
next if defined($previous) && $previous eq $item;
print {$tfh} $item, $INPUT_RECORD_SEPARATOR;
}
@$records = ();
seek $tfh, 0, SEEK_SET;
return $tfh;
}
lib/App/Sets/Sort.pm view on Meta::CPAN
my $best = $its{$fk}[1];
for my $key (@keys) {
my $head = $its{$key}[1];
$best = $head if $best gt $head;
}
print {$ofh} $best, $INPUT_RECORD_SEPARATOR;
# get rid of the best in all iterators, cleanup on the way
KEY:
for my $key ($fk, @keys) {
my $head = $its{$key}[1];
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/SilverSplash/IPTables.pm view on Meta::CPAN
join( "\n", map { sprintf( $slout, $_, 443 ) } @{$sslhosts_allow} );
##############################
# add the filter default chains
my $filters = <<"FILTERS";
INPUT -i $Lan_if -j slRTR
FORWARD -i $Lan_if -j slNET
slAUT --protocol tcp --source-port ! 25 -j ACCEPT
view all matches for this distribution
view release on metacpan or search on metacpan
local/lib/perl5/x86_64-linux-gnu-thread-multi/Compress/Raw/Lzma.pm view on Meta::CPAN
}
use constant FLAG_APPEND => 1 ;
use constant FLAG_CRC => 2 ;
use constant FLAG_ADLER => 4 ;
use constant FLAG_CONSUME_INPUT => 8 ;
use constant FLAG_LIMIT_OUTPUT => 16 ;
eval {
require XSLoader;
XSLoader::load('Compress::Raw::Lzma', $XS_VERSION);
1;
local/lib/perl5/x86_64-linux-gnu-thread-multi/Compress/Raw/Lzma.pm view on Meta::CPAN
}, @_) ;
my $flags = 0 ;
$flags |= FLAG_APPEND if $got->value('AppendOutput') ;
$flags |= FLAG_CONSUME_INPUT if $got->value('ConsumeInput') ;
$flags |= FLAG_LIMIT_OUTPUT if $got->value('LimitOutput') ;
lzma_auto_decoder($pkg, $flags, $got->value('MemLimit'));
}
@Compress::Raw::Lzma::AloneDecoder::ISA = qw(Compress::Raw::Lzma::Decoder);
local/lib/perl5/x86_64-linux-gnu-thread-multi/Compress/Raw/Lzma.pm view on Meta::CPAN
}, @_) ;
my $flags = 0 ;
$flags |= FLAG_APPEND if $got->value('AppendOutput') ;
$flags |= FLAG_CONSUME_INPUT if $got->value('ConsumeInput') ;
$flags |= FLAG_LIMIT_OUTPUT if $got->value('LimitOutput') ;
lzma_alone_decoder($pkg,
$flags,
$got->value('Bufsize'),
$got->value('MemLimit'));
local/lib/perl5/x86_64-linux-gnu-thread-multi/Compress/Raw/Lzma.pm view on Meta::CPAN
}, @_) ;
my $flags = 0 ;
$flags |= FLAG_APPEND if $got->value('AppendOutput') ;
$flags |= FLAG_CONSUME_INPUT if $got->value('ConsumeInput') ;
$flags |= FLAG_LIMIT_OUTPUT if $got->value('LimitOutput') ;
lzma_stream_decoder($pkg,
$flags,
$got->value('Bufsize'),
$got->value('MemLimit'),
local/lib/perl5/x86_64-linux-gnu-thread-multi/Compress/Raw/Lzma.pm view on Meta::CPAN
}, @_) ;
my $flags = 0 ;
$flags |= FLAG_APPEND if $got->value('AppendOutput') ;
$flags |= FLAG_CONSUME_INPUT if $got->value('ConsumeInput') ;
$flags |= FLAG_LIMIT_OUTPUT if $got->value('LimitOutput') ;
my $filters = Lzma::Filters::validateFilters(0, ! defined $got->value('Properties'),
$got->value('Filter')) ;
lzma_raw_decoder($pkg,
view all matches for this distribution
view release on metacpan or search on metacpan
t/lib/TestsFor/App/SimulateReads/Simulator.pm view on Meta::CPAN
SEQID_WEIGHT => 'length',
SEQUENCING_TYPE => 'paired-end',
SEQUENCING_SYSTEM => 'poisson',
SEED => time,
JOBS => 2,
OUTPUT_GZIP => 0,
SEQ_SYS => 'poisson',
QUALITY_SIZE => 10,
GENOME => '.data.fa',
GENOME_SIZE => 2280,
COVERAGE => 5,
PREFIX => 'ponga',
OUTPUT_SINGLE_END => 'ponga_R1_001.fastq',
OUTPUT_PAIRED_END => ['ponga_R1_001.fastq', 'ponga_R2_001.fastq'],
OUTPUT_COUNTS => 'ponga_counts.tsv'
};
sub startup : Tests(startup) {
my $test = shift;
$test->SUPER::startup;
t/lib/TestsFor/App/SimulateReads/Simulator.pm view on Meta::CPAN
$LOG_VERBOSE = VERBOSE;
$test->SUPER::setup;
my %default_attr = (
prefix => PREFIX,
output_gzip => OUTPUT_GZIP,
fasta_file => GENOME,
coverage => COVERAGE,
jobs => JOBS,
seqid_weight => 'length',
count_loops_by => 'coverage',
t/lib/TestsFor/App/SimulateReads/Simulator.pm view on Meta::CPAN
}
}
sub run_simulation : Tests(9) {
my $test = shift;
my $output_single_end = OUTPUT_SINGLE_END;
my $output_paired_end = OUTPUT_PAIRED_END;
my $output_counts = OUTPUT_COUNTS;
my $fastq_count = sub {
my $file = shift;
my $entries = 0;
my %chr_acm;
view all matches for this distribution
view release on metacpan or search on metacpan
share/public/slides.js view on Meta::CPAN
else
console.log("Can't send: ", obj);
},
// Return true if the input event is destined for a DOM node that takes input
_event_is_for_input: function(e) {
return (e.target.tagName == "INPUT"
|| (e.target.tagName == "BUTTON" && e.type == 'click')
|| e.target.tagName == "TEXTAREA"
) || (e.originalEvent && this._event_is_for_input(e.originalEvent));
},
_handle_key: function(e) {
view all matches for this distribution
view release on metacpan or search on metacpan
socialcalc/LICENSE.txt view on Meta::CPAN
UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT (INCLUDING NEGLIGENCE), CONTRACT,
OR OTHERWISE, SHALL YOU, THE INITIAL DEVELOPER, ORIGINAL DEVELOPER, ANY OTHER CONTRIBUTOR, OR
ANY DISTRIBUTOR OF COVERED CODE, OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON
FOR ANY INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING,
WITHOUT LIMITATION, DAMAGES FOR LOSS OF GOODWILL, WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION,
OR ANY AND ALL OTHER COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF
THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF LIABILITY SHALL NOT APPLY TO LIABILITY FOR
DEATH OR PERSONAL INJURY RESULTING FROM SUCH PARTYS NEGLIGENCE TO THE EXTENT APPLICABLE LAW
PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF
INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/SpreadRevolutionaryDate.pm view on Meta::CPAN
use Locale::TextDomain 'App-SpreadRevolutionaryDate';
use Locale::Messages qw(bind_textdomain_filter);
use Encode;
BEGIN {
$ENV{OUTPUT_CHARSET} = 'UTF-8';
bind_textdomain_filter 'App-SpreadRevolutionaryDate' => \&Encode::decode_utf8, Encode::FB_DEFAULT;
}
use namespace::autoclean;
has 'config' => (
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/SpreadsheetUtils.pm view on Meta::CPAN
To read CSV data, normally your utility would provide handler for the
`on_input_data_row` hook and sometimes additionally `on_input_header_row`.
*OUTPUTTING STRING OR RETURNING RESULT*
To output string, usually you call the provided routine `$r->{code_print}`. This
routine will open the output files for you.
You can also return enveloped result directly by setting `$r->{result}`.
*OUTPUTTING CSV DATA*
To output CSV data, usually you call the provided routine `$r->{code_print_row}`.
This routine accepts a row (arrayref or hashref). This routine will open the
output files for you when needed, as well as print header row automatically.
lib/App/SpreadsheetUtils.pm view on Meta::CPAN
as usual. To switch to the next file, set
`$r->{wants_switch_to_next_output_file}` to true, in which case the next call to
`$r->{code_print_row}` will close the current file and open the next file.
*CHANGING THE OUTPUT FIELDS*
When calling `$r->{code_print_row}`, you can output whatever fields you want. By
convention, you can set `$r->{output_fields}` and `$r->{output_fields_idx}` to
let other handlers know about the output fields. For example, see the
implementation of <prog:csv-concat>.
lib/App/SpreadsheetUtils.pm view on Meta::CPAN
} else {
@input_filenames = ($util_args{input_filename} // '-');
}
$r->{input_filenames} //= \@input_filenames;
BEFORE_INPUT_FILENAME:
$r->{input_filenum} = 0;
INPUT_FILENAME:
for my $input_filename (@input_filenames) {
$r->{input_filenum}++;
$r->{input_filename} = $input_filename;
if ($r->{input_filenum} == 1 && $before_open_input_files) {
lib/App/SpreadsheetUtils.pm view on Meta::CPAN
if ($before_open_input_file) {
log_trace "Calling before_open_input_file handler ...";
$before_open_input_file->($r);
if (delete $r->{wants_skip_file}) {
log_trace "Handler wants to skip this file, moving on to the next file";
next INPUT_FILENAME;
} elsif (delete $r->{wants_skip_files}) {
log_trace "Handler wants to skip all files, skipping all input files";
last READ_CSV;
}
}
lib/App/SpreadsheetUtils.pm view on Meta::CPAN
log_trace "Calling on_input_header_row hook handler ...";
$on_input_header_row->($r);
if (delete $r->{wants_skip_file}) {
log_trace "Handler wants to skip this file, moving on to the next file";
next INPUT_FILENAME;
} elsif (delete $r->{wants_skip_files}) {
log_trace "Handler wants to skip all files, skipping all input files";
last READ_CSV;
}
}
lib/App/SpreadsheetUtils.pm view on Meta::CPAN
log_trace "Calling on_input_data_row hook handler (for first data row) ..." if $r->{input_rownum} <= 2;
$on_input_data_row->($r);
if (delete $r->{wants_skip_file}) {
log_trace "Handler wants to skip this file, moving on to the next file";
next INPUT_FILENAME;
} elsif (delete $r->{wants_skip_files}) {
log_trace "Handler wants to skip all files, skipping all input files";
last READ_CSV;
}
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Sqitch.pm view on Meta::CPAN
our $VERSION = 'v1.5.2'; # VERSION
BEGIN {
# Force Locale::TextDomain to encode in UTF-8 and to decode all messages.
$ENV{OUTPUT_CHARSET} = 'UTF-8';
bind_textdomain_filter 'App-Sqitch' => \&Encode::decode_utf8, Encode::FB_DEFAULT;
}
# Okay to load Sqitch classes now that types are created.
use App::Sqitch::Config;
view all matches for this distribution
view release on metacpan or search on metacpan
--delimiter|d=<value> # default: "\t"
--no-header|nh # don't display header
--transpose-output|to # switch rows and columns
=head3 INPUT VALIDATION
By default, C<st> skips invalid input with a warning.
You can change this behavior with the following options:
view all matches for this distribution
view release on metacpan or search on metacpan
PUSHmortal|5.009002||p
PUSHn|||
PUSHp|||
PUSHs|||
PUSHu|5.004000||p
PUTBACK|||
PerlIO_clearerr||5.007003|
PerlIO_close||5.007003|
PerlIO_context_layers||5.009004|
PerlIO_eof||5.007003|
PerlIO_error||5.007003|
eval_sv(sv, G_SCALAR);
SvREFCNT_dec(sv);
SPAGAIN;
sv = POPs;
PUTBACK;
if (croak_on_error && SvTRUE(GvSV(errgv)))
croak(SvPVx(GvSV(errgv), na));
return sv;
view all matches for this distribution
view release on metacpan or search on metacpan
t/01_vollwaesche.t view on Meta::CPAN
if (my $exit = system "exec >$PFX/output 2>&1; $command") {
my $output = do { local *FH; open FH, "<$PFX/output" or die "$PFX/output: $!"; local $/; <FH> };
$output = substr $output, -30000 if 30000 < length $output; # "output truncated after..." I wish they would document these things
printf STDERR
"\n\n# FAILED #%d exit status 0x%04x (%s)\n\n# OUTPUT:\n%s\n\n",
$test, $exit, $command, $output;
print "not ok $test\n";
} else {
print "ok $test\n";
}
view all matches for this distribution
view release on metacpan or search on metacpan
script/vtt2srt view on Meta::CPAN
This document describes version 0.014 of vtt2srt (from Perl distribution App-SubtitleUtils), released on 2025-07-15.
=head1 SYNOPSIS
% vtt2srt < INPUT.vtt > OUTPUT.srt
=head1 HOMEPAGE
Please visit the project's homepage at L<https://metacpan.org/release/App-SubtitleUtils>.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Sysadmin/Log/Simple/HTTP.pm view on Meta::CPAN
return $ua->post_form($self->{http}->{uri}, {
user => $self->{user},
log => $logentry,
});
}
elsif ( $self->{http}->{method} eq 'PUT' ) {
return $ua->put($self->{http}->{uri}, {
user => $self->{user},
log => $logentry,
});
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Table2YAML/Loader/AsciiTable.pm view on Meta::CPAN
our $VERSION = '0.003'; # VERSION
sub load_asciitable {
my $self = shift;
local $INPUT_RECORD_SEPARATOR = $self->record_separator();
my $ref = ref $self->input() || q();
my $ascii_fh
= $ref eq q(GLOB)
? $self->input()
: IO::File->new( $self->input(), q(r) );
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/TemplateServer.pm view on Meta::CPAN
map_foo_bar:
- ["foo"]
- "bar"
- ["bar"]
- "foo"
- "INVALID INPUT"
instantiate:
test_instance: "Test"
another_test_instance:
Test: "new"
This makes the variables C<foo>, C<test_instance>, and
C<another_test_instance> available in the templates. It also creates
a package called C<Test> and adds a constructor called C<new>, and a
method called C<map_foo_bar> that returns "bar" when the argument is
"foo", "foo" when the argument is "bar", and "INVALID INPUT"
otherwise.
=head3 DESCRIPTION
Any key/value pair other than C<packages> and C<instantiate> is
view all matches for this distribution
view release on metacpan or search on metacpan
} ;
$yaml = "---\n$yaml\n" ;
my $directory_structure = Load($yaml) ;
DumpTree $directory_structure, 'munged', NO_OUTPUT => 1, FILTER => $get_db_paths ;
#diag "YAML\n$yaml\n";
#diag DumpTree $directory_structure, 'Directories' ;
#diag DumpTree \%db_paths, 'DB' ;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Textcast.pm view on Meta::CPAN
use strict;
use warnings ;
use Carp qw(carp croak confess) ;
use English qw( -no_match_vars ) ;
$OUTPUT_AUTOFLUSH++;
my $get_terminal_size ;
BEGIN
{
lib/App/Textcast.pm view on Meta::CPAN
use App::Textcast 'record_textcast' ;
record_textcast
(
COMMAND => 'bash',
OUTPUT_DIRECTORY => shift @ARGV,
COMPRESS => $compress,
COLUMNS => $columns,
ROWS => $rows,
) ;
lib/App/Textcast.pm view on Meta::CPAN
=over 2
=item * COMMAND => $string - the name of the command to tun in a terminal. You most probably wan to run
I<bash> or I<sh>
=item * OUTPUT_DIRECTORY => $directory_path - Optional - the path to the directory where the textcast is to be
recorded. This subroutine will create a directory if this option is not set. if this option is set, the directory
should not exist.
=item * COMPRESS => $boolean - Not implemented
lib/App/Textcast.pm view on Meta::CPAN
my (%arguments) = @_;
my ($terminal_columns, $terminal_rows) = $get_terminal_size->() ;
my $output_directory = check_output_directory($arguments{OUTPUT_DIRECTORY}) ;
my $vt_process = create_vt102_sub_process
(
$arguments{COMMAND},
$arguments{COLUMNS} || $terminal_columns,
$arguments{ROWS} || $terminal_rows,
lib/App/Textcast.pm view on Meta::CPAN
my $vt = Term::VT102->new (cols => $columns, rows => $rows,);
$vt->option_set ('LFTOCRLF', 1); # Convert linefeeds to linefeed + carriage return.
$vt->option_set ('LINEWRAP', 1); # Make sure line wrapping is switched on.
# Set up the callback for OUTPUT; this callback function simply sends
# whatever the Term::VT102 module wants to send back to the terminal and
# sends it to the child process - see its definition below.
$vt->callback_set ('OUTPUT', \&vt_output, $pty);
# Set up a callback for row changes, so we can process updates and display
# them without having to redraw the whole screen every time. We catch CLEAR,
# SCROLL_UP, and SCROLL_DOWN with another function that triggers a
# whole-screen repaint. You could process SCROLL_UP and SCROLL_DOWN more
lib/App/Textcast.pm view on Meta::CPAN
sub vt_output
{
=head2 [p] vt_output($vtobject, $type, $arg1, $arg2, $private)
Callback for OUTPUT events - for Term::VT102.
I<Arguments>
=over 2
lib/App/Textcast.pm view on Meta::CPAN
=cut
my ($vtobject, $type, $arg1, $arg2, $private) = @_;
if ($type eq 'OUTPUT')
{
$private->syswrite ($arg1, length $arg1);
}
return ;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/TimeTracker/Command/Gitlab.pm view on Meta::CPAN
$self->branch( lc($branch) ) unless $self->branch;
}
# reopen
if ($self->config->{gitlab}{reopen} && $issue->{state} eq 'closed') {
$self->_call('PUT','projects/'.$self->project_id.'/issues/'.$self->issue.'?state_event=reopen');
say "reopend closed issue";
}
# set assignee
if ($self->config->{gitlab}{set_assignee}) {
lib/App/TimeTracker/Command/Gitlab.pm view on Meta::CPAN
if ($assignee ne $user->{username}) {
warning_message("Assignee already set to ".$assignee);
}
}
else {
$self->_call('PUT','projects/'.$self->project_id.'/issues/'.$self->issue.'?assignee_id='.$user->{id});
say "Assignee set to you";
}
}
else {
error_message("Cannot get user-id, thus cannot assign issue");
lib/App/TimeTracker/Command/Gitlab.pm view on Meta::CPAN
if (my $remove = $on_start->{remove}) {
foreach my $remove (@$remove) {
delete $l{$remove};
}
}
$self->_call('PUT','projects/'.$self->project_id.'/issues/'.$self->issue.'?labels='.uri_escape(join(',',keys %l)));
say "Labels are now: ".join(', ',sort keys %l);
}
};
#after [ 'cmd_start', 'cmd_continue', 'cmd_append' ] => sub {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Validation/Automation/Logging.pm view on Meta::CPAN
sub log {
my $self = shift;
my $msg = shift;
local $OUTPUT_AUTOFLUSH = 1;
print { $self->log_file_handle }
scalar(localtime(time)).caller()." $msg"."\n" if( $msg );
return 1;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Waf.pm view on Meta::CPAN
my $ips = `/sbin/iptables-save`;
my @ipsline = split /\n/sm, $ips;
my $dist = 0;
for (@ipsline) {
$dist = 1 if ( /$IP/ and /INPUT/ and /DROP/ );
}
unless ($dist) {
`/sbin/iptables -I INPUT -s $IP -j DROP`;
my $btime = localtime( time() );
print "$btime :band $IP \n";
}
else {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Widget/JSApp/TabbedAppFrame.pm view on Meta::CPAN
######################################################################
# ATTRIBUTES
######################################################################
# INPUTS FROM THE ENVIRONMENT
=head1 DESCRIPTION
This class implements an application frame.
This includes a menu, an application toolbar, a screen selector,
lib/App/Widget/JSApp/TabbedAppFrame.pm view on Meta::CPAN
configured to do so. Otherwise, it implements itself as a table.
=cut
######################################################################
# OUTPUT METHODS
######################################################################
sub _init {
&App::sub_entry if ($App::trace);
my $self = shift;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/App/Widget/AppFrame.pm view on Meta::CPAN
######################################################################
# ATTRIBUTES
######################################################################
# INPUTS FROM THE ENVIRONMENT
=head1 DESCRIPTION
This class implements an application frame.
This includes a menu, an application toolbar, a screen selector,
lib/App/Widget/AppFrame.pm view on Meta::CPAN
}
}
######################################################################
# OUTPUT METHODS
######################################################################
sub html {
my $self = shift;
my ($context, $name, $html);
view all matches for this distribution
view release on metacpan or search on metacpan
bin/docmake view on Meta::CPAN
Use the DocBook xsl-ns ( namespaces ) URLs.
Verbose - output the commands' invocation as they are executed.
=item * -o OUTPUT_PATH
Put the result in B<OUTPUT_PATH> .
=item * -x STYLESHEET ; --stylesheet STYLESHEET
Use the XSLT stylesheet B<STYLESHEET> for performing XSLT transformations.
view all matches for this distribution
view release on metacpan or search on metacpan
script/youtube-dl-play view on Meta::CPAN
% youtube-dl [OPTS] --get-filename <URL_OR_VIDEO_ID>
=item * Run youtube-dl that outputs to stdout and pipe it to mpv
% youtube-dl [OPTS] -o - <URL_OR_VIDEO_ID> | tee <OUTPUTFILENAME> | mpv -
=back
Some caveats:
view all matches for this distribution
view release on metacpan or search on metacpan
script/yt-dlp-play view on Meta::CPAN
% yt-dlp [OPTS] --get-filename <URL_OR_VIDEO_ID>
=item * Run yt-dlp that outputs to stdout and pipe it to mpv
% yt-dlp [OPTS] -o - <URL_OR_VIDEO_ID> | tee <OUTPUTFILENAME> | mpv -
=back
Some caveats:
view all matches for this distribution
view release on metacpan or search on metacpan
script/_chinese-zodiac-of view on Meta::CPAN
# my $mode = '>';
# if ($filename =~ /^\s*(>{1,2})\s*(.*)$/) {
# ($mode, $filename) = ($1, $2);
# }
# open $OUT, $mode, $filename
# or YAML::Old::Mo::Object->die('YAML_DUMP_ERR_FILE_OUTPUT', $filename, "$!");
# }
# binmode $OUT, ':utf8'; # if $Config{useperlio} eq 'define';
# local $/ = "\n"; # reset special to "sane"
# print $OUT Dump(@_);
# unless (ref $filename eq 'GLOB') {
# close $OUT
# or do {
# my $errsav = $!;
# YAML::Old::Mo::Object->die('YAML_DUMP_ERR_FILE_OUTPUT_CLOSE', $filename, $errsav);
# }
# }
#}
#
#sub LoadFile {
script/_chinese-zodiac-of view on Meta::CPAN
# if (openhandle $filename) {
# $IN = $filename;
# }
# else {
# open $IN, '<', $filename
# or YAML::Old::Mo::Object->die('YAML_LOAD_ERR_FILE_INPUT', $filename, "$!");
# }
# binmode $IN, ':utf8'; # if $Config{useperlio} eq 'define';
# return Load(do { local $/; <$IN> });
#}
#
script/_chinese-zodiac-of view on Meta::CPAN
# Can't parse node
#YAML_PARSE_ERR_BAD_EXPLICIT
# Unsupported explicit transfer: '%s'
#YAML_DUMP_USAGE_DUMPCODE
# Invalid value for DumpCode: '%s'
#YAML_LOAD_ERR_FILE_INPUT
# Couldn't open %s for input:\n%s
#YAML_DUMP_ERR_FILE_CONCATENATE
# Can't concatenate to YAML file %s
#YAML_DUMP_ERR_FILE_OUTPUT
# Couldn't open %s for output:\n%s
#YAML_DUMP_ERR_FILE_OUTPUT_CLOSE
# Error closing %s:\n%s
#YAML_DUMP_ERR_NO_HEADER
# With UseHeader=0, the node must be a plain hash or array
#YAML_DUMP_WARN_BAD_NODE_TYPE
# Can't perform serialization for node type: '%s'
view all matches for this distribution