Mercurial > hg > cc > cirrus_home
annotate bin/unfold.sh @ 190:f2bf736c2d40
working, with issues:
1) warc.export.cdx.path is not set
2) mime property isn't getting through
3) lastMod isn't showing up
| author | Henry S. Thompson <ht@inf.ed.ac.uk> |
|---|---|
| date | Tue, 24 Sep 2024 17:08:05 +0100 |
| parents | a82c325e8b32 |
| children |
| rev | line source |
|---|---|
| 18 | 1 #!/bin/bash |
| 2 # Usage: unfold.sh links_... | |
| 3 pdfs=/beegfs/common_crawl/CC-MAIN-2019-35/pdfs | |
| 4 links=$pdfs/links | |
| 5 f=$1 | |
| 25 | 6 IFS=' ' |
| 18 | 7 awk '{if (NR==1) { o=$1 ; u=$2 } |
| 8 else | |
| 9 { if ($1=="annot" || $1=="scrape") { | |
| 10 print o,"\t",u | |
| 11 o=$1 | |
| 12 u=$2 | |
| 13 } | |
| 14 else { | |
| 15 u=u $1 | |
| 16 } | |
| 17 } | |
| 18 } | |
| 19 END { print o,"\t",u }' $f |
