From 0dc0de6b5022c6f6a3ac88d7c25c063784c21c6f Mon Sep 17 00:00:00 2001 From: JustAnotherArchivist Date: Fri, 19 Jul 2019 12:48:19 +0000 Subject: [PATCH] Add support for lists --- youtube-normalise | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/youtube-normalise b/youtube-normalise index 169cd6e..50f19cf 100755 --- a/youtube-normalise +++ b/youtube-normalise @@ -1,6 +1,14 @@ #!/bin/bash while read -r url do + if [[ "${url}" == '* '* ]] + then + prefix='* ' + url="${url:2}" + else + prefix='' + fi + if [[ "${url}" =~ ^https?://(www\.)?youtube\.com/ ]] then if [[ "${url}" == *'?'* ]] @@ -13,17 +21,17 @@ do canonical="$(grep -Po '