1
0
Fork 0
mirror of synced 2024-10-02 01:57:20 +13:00
bulk-downloader-for-reddit/scripts/extract_successful_ids.sh

18 lines
493 B
Bash
Raw Normal View History

2021-05-01 15:23:31 +12:00
#!/bin/bash
if [ -e "$1" ]; then
file="$1"
else
echo "CANNOT FIND LOG FILE"
2021-05-01 15:23:31 +12:00
exit 1
fi
2021-05-22 13:47:59 +12:00
{
grep "Downloaded submission" "$file" | awk "{ print $(NF-2) }" ;
grep "Resource hash" "$file" | awk "{ print $(NF-2) }" ;
grep "Download filter" "$file" | awk "{ print $(NF-3) }" ;
grep "already exists, continuing" "$file" | awk "{ print $(NF-3) }" ;
grep "Hard link made" "$file" | awk "{ print $(NF) }" ;
grep "filtered due to score" "$file" | awk "{ print $9 }"
2022-04-19 13:47:35 +12:00
}