summaryrefslogtreecommitdiff
path: root/bin/common/y2chid
diff options
context:
space:
mode:
Diffstat (limited to 'bin/common/y2chid')
-rwxr-xr-xbin/common/y2chid7
1 files changed, 7 insertions, 0 deletions
diff --git a/bin/common/y2chid b/bin/common/y2chid
new file mode 100755
index 0000000..68ba6bc
--- /dev/null
+++ b/bin/common/y2chid
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+test -z "${chidot:=$1}" \
+ && chidot="$(cat /dev/stdin)"
+
+echo "chidot: ${chidot}" 1>&2
+curl -s "https://www.youtube.com/${chidot}/"| pup 'meta[itemprop="channelId"] attr{content}'