Skip to content

Commit 630d84e

Browse files
committed
[Update] Code
1 parent 7e7870a commit 630d84e

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

0x22-YouTubeViewer/pythonVideo.py

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import vlc
2+
3+
import pafy
4+
5+
url = "https://www.youtube.com/watch?v=LA9tjiiAvN0&pp=ygUjcGFydGl0aWlvbmluZyBzdG9yYWdlIG9uIHdpbmRvd3MgMTE%3D"
6+
7+
video = pafy.new(url)
8+
best = video.getbest()
9+
media = vlc.MediaPlayer(best.url)
10+
11+
media.play()

0 commit comments

Comments
 (0)