Linked List

A personal knowledge base

RSS Feed Manipulation

#Find items in feed XML with more than one enclosure

for file in *; do
  echo "$file"
  xpath "$file"  '//item[enclosure][count(enclosure) > 1]'
  echo "-----"
done

#To find enclosures in above

//item[enclosure][count(enclosure) > 1]/enclosure

#Fetch feeds from OPML

grep -Eo 'xmlUrl="[^"]+"' Podcasts.opml | grep -oE 'http:[^"]+' | wget -i -

#Find extensions used in feeds

grep -hEro "enclosure url=[\"'][^\"']+[\"']" .| grep -Eo "\.[^.]+[\"']"|sort -u

#Find content types used in feed

grep -Eohr "type=[\"'][^'\"]+[\"']" .|sort -u
Last modified: 03 Oct 2015