aboutsummaryrefslogtreecommitdiff
path: root/.local/share
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-08-03 19:35:53 +0200
committerLoek Le Blansch <loek@pipeframe.xyz>2024-08-03 19:35:53 +0200
commit0189da0878613b92afc5a93432e57fb6f419688b (patch)
treee238a49544c15000323f13224d2aec1d7ff3969d /.local/share
parent329f9e177c087bc7a16d559db0d8104d6733f3b5 (diff)
add script for quickly viewing youtube live stream chat dumps
Diffstat (limited to '.local/share')
-rwxr-xr-x.local/share/bin/vodchat3
1 files changed, 3 insertions, 0 deletions
diff --git a/.local/share/bin/vodchat b/.local/share/bin/vodchat
new file mode 100755
index 0000000..f233348
--- /dev/null
+++ b/.local/share/bin/vodchat
@@ -0,0 +1,3 @@
+#!/bin/sh
+input_file="$1"
+jq --raw-output '.replayChatItemAction.actions[].addChatItemAction.item.liveChatTextMessageRenderer | "[" + (.timestampUsec | tonumber / 1e6 | todateiso8601) + "] " + .authorName.simpleText + ": " + .message.runs[].text' "$input_file" 2>/dev/null