]> njoseph.me Git - nimcoon.git/commitdiff
Add PeerTube support
authorJoseph Nuthalapati <njoseph@riseup.net>
Mon, 23 Dec 2019 12:53:22 +0000 (18:23 +0530)
committerJoseph Nuthalapati <njoseph@riseup.net>
Mon, 23 Dec 2019 12:53:22 +0000 (18:23 +0530)
Now we have two supported video platforms: YouTube and PeerTube

Signed-off-by: Joseph Nuthalapati <njoseph@riseup.net>
README.md
clitube.nim

index 863a48f73037f5c253154b676218c46ae8962a0f..3838642ac9556c8930afc57bd17ecea9de57ddf2 100644 (file)
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
 # CLI Tube
 
-Play videos from YouTube (and maybe other sources in the future) from the
+Play videos from YouTube and PeerTube from the
 command line using your preferred desktop media player.
 
 This application is implemented in [Nim language](https://nim-lang.org) using
index 50a3f67a17838f87c3f8b355a5bfdd2df37bce34..cc354483cdba5a8faab5b59c7bac86f32086799f 100644 (file)
@@ -56,7 +56,7 @@ for kind, key, value in getopt():
     discard
 
 
-if "https://www.youtube.com" in searchQuery:
+if "?watch" in searchQuery or "videos/watch" in searchQuery :
   discard execProcess(&"{player} {searchQuery}")
   quit(0)