diff --git a/bin/gtk-pipe-viewer b/bin/gtk-pipe-viewer index c7d895a..b994081 100755 --- a/bin/gtk-pipe-viewer +++ b/bin/gtk-pipe-viewer @@ -151,21 +151,15 @@ my %CONFIG = ( srt => q{--sub-file=*SUB*}, audio => q{--input-slave=*AUDIO*}, fs => q{--fullscreen}, - arg => q{--quiet --play-and-exit --no-video-title-show --input-title-format=*TITLE*}, + arg => q{--quiet --play-and-exit --no-video-title-show --input-title-format=*TITLE* *VIDEO*}, }, mpv => { cmd => q{mpv}, srt => q{--sub-file=*SUB*}, audio => q{--audio-file=*AUDIO*}, fs => q{--fullscreen}, - arg => q{--really-quiet --force-media-title=*TITLE* --no-ytdl}, + arg => q{--really-quiet --force-media-title=*TITLE* --no-ytdl *VIDEO*}, }, - smplayer => { - cmd => q{smplayer}, - srt => q{-sub *SUB*}, - fs => q{-fullscreen}, - arg => q{-close-at-end -media-title *TITLE* *URL*}, - }, }, video_player_selected => undef, # autodetect it later @@ -3044,7 +3038,7 @@ sub get_player_command { ) ); - my $has_video = $cmd =~ /\*(?:VIDEO|URL|ID)\*/; + my $has_video = $cmd =~ /(?:^|\s)\*(?:VIDEO|URL)\*(?:\s|\z)/; $cmd = $yv_utils->format_text( streaming => $streaming, diff --git a/bin/pipe-viewer b/bin/pipe-viewer index 2258c1f..008e8e2 100755 --- a/bin/pipe-viewer +++ b/bin/pipe-viewer @@ -144,7 +144,7 @@ my %CONFIG = ( srt => q{--sub-file=*SUB*}, audio => q{--input-slave=*AUDIO*}, fs => q{--fullscreen}, - arg => q{--quiet --play-and-exit --no-video-title-show --input-title-format=*TITLE*}, + arg => q{--quiet --play-and-exit --no-video-title-show --input-title-format=*TITLE* *VIDEO*}, novideo => q{--intf=dummy --novideo}, }, mpv => { @@ -152,7 +152,7 @@ my %CONFIG = ( srt => q{--sub-file=*SUB*}, audio => q{--audio-file=*AUDIO*}, fs => q{--fullscreen}, - arg => q{--really-quiet --force-media-title=*TITLE* --no-ytdl}, + arg => q{--really-quiet --force-media-title=*TITLE* --no-ytdl *VIDEO*}, novideo => q{--no-video}, }, }, @@ -3355,7 +3355,7 @@ sub get_player_command { ) ); - my $has_video = $cmd =~ /\*(?:VIDEO|URL|ID)\*/; + my $has_video = $cmd =~ /(?:^|\s)\*(?:VIDEO|URL)\*(?:\s|\z)/; $cmd = $yv_utils->format_text( streaming => $streaming,