App-YTDL

 view release on metacpan or  search on metacpan

bin/getvideo  view on Meta::CPAN

        #if ( $opt->{menu_memory} ) {
        #    if ( $old_idx == $idx && ! $ENV{TC_RESET_AUTO_UP} ) {
        #        $old_idx = 0;
        #        next MENU;
        #    }
        #    $old_idx = $idx;
        #}
        if ( $menu->[$idx] eq $uploader ) {
            my @chosen_uploaders = choose_videos_from_saved_uploaders( $set, $opt );
            next if ! @chosen_uploaders;
            my $chosen = from_arguments_to_choices( $set, $opt, $urls_data, $data, @chosen_uploaders );
            print_video_infos( $set, $opt, $data, $chosen );
            my $total = download( $set, $opt, $data, $chosen );
            $clear_screen = $total ? 0 : 1;
            say "";
        }
        elsif ( $menu->[$idx] eq $sticky ) {
           edit_sticky_file( $set, $opt );
        }
    }
}


if ( ! @ids ) {
    say "No arguments" and exit;
}



__END__

=pod

=encoding UTF-8

=head1 NAME

getvideo - Download YouTube and other videos.

=head1 VERSION

Version 0.417

=cut

=head1 SYNOPSIS

    getvideo -h|-?|--help

    getvideo

    getvideo url [url ...]

    getvideo -f|--file filename

=head1 DESCRIPTION

Download single videos or choose videos from a playlist or an uploader.

Call C<getvideo> followed by the space separated urls or enter the urls after calling C<getvideo>. If the urls are
entered after calling C<getvideo>, shell metacharacters are escaped automatically.

The urls can also be passed with a file: C<getvideo -f|--file filename>. The urls in the file have to be space separated.

If a passed url results in more than one video, it is shown a menu with the video titles. The user can then choose from
the menu which videos to download. It is possible to filter the video titles of the list menu with a regexp. The filter
can be inverted by adding C<!~> and a space in front of the regexp. Use the C<SpaceBar> to select more than one video -
see L<Term::Choose/USAGE-AND-RETURN-VALUES>.

The different options of C<getvideo> can be reached by calling C<getvideo -h>.

C<App::YTDL> uses L<youtube-dl|http://rg3.github.io/youtube-dl/> to get the info data and to download the videos. To
list the extractors supported by C<youtube-dl> call C<getvideo -h> and select the entry I<List extractors>.

=head1 Options

=head2 HELP

Shows this HELP text.

=head2 INFO

Shows the path and the version of the running C<getvideo>, the path of the video and configuration directories and the
version of C<youtube-dl>. If C<ffmpeg> and C<ffprobe> are available, their version is also shown.

=head2 Directory

=head3 Video directory

Choose an alternative main video directory.

=head3 Extractor directory

Create/use extractor directories.

- no

- yes

=head3 Uploader directory

Create/use uploader directories

- no

- yes

- if chosen from an uploader or a playlist

=head3 Filename format info

Which format info should be added to the filename.

- none (unsafe)

- video-height (unsafe)

- format-id

- format-id and video-height



( run in 0.866 second using v1.01-cache-2.11-cpan-ceb78f64989 )