aboutsummaryrefslogtreecommitdiff
path: root/web-player
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2024-08-20 21:01:32 -0300
committerSilvio Rhatto <rhatto@riseup.net>2024-08-20 21:01:32 -0300
commitc3a1bf60e9694b6ac725016a15f19f49905e541f (patch)
treea35339e755a19e525342861d7fad5ec4e3e99db0 /web-player
downloadutils-web-main.tar.gz
utils-web-main.tar.bz2
Initial importmain
Diffstat (limited to 'web-player')
-rwxr-xr-xweb-player18
1 files changed, 18 insertions, 0 deletions
diff --git a/web-player b/web-player
new file mode 100755
index 0000000..dcbbb5c
--- /dev/null
+++ b/web-player
@@ -0,0 +1,18 @@
+#!/bin/bash
+#
+# Web media player from the command line
+# https://unix.stackexchange.com/questions/160212/watch-youtube-videos-in-terminal
+#
+
+# Parameters
+BASENAME="`basename $0`"
+URL="$1"
+
+# Check
+if [ -z "$1" ]; then
+ echo "usage: $BASENAME <url>"
+ exit 1
+fi
+
+# Run
+yt-dlp $URL -o - | mpv -vo aa -monitorpixelaspect 0.5 -