speed up!

This commit is contained in:
Stefen Auris 2022-12-04 15:53:04 -05:00
parent 19182f3d4c
commit 75c6765312

View file

@ -1,15 +1,14 @@
#!/bin/bash
N=2
N=4
cd $HOME/gallery-dl/twitter
for i in */; do
echo ">> $i"
(gallery-dl --sleep 0-1 --abort 3 "https://twitter.com/$i" || echo "Problem with $i gallery!" >> ~/twit_error.txt) &
(gallery-dl --sleep 0-1 --abort 3 "https://twitter.com/$i" || echo "Problem with gallery at https://twitter.com/$i" >> ~/twit_error.txt) &
if [[ $(jobs -r -p | wc -l) -ge $N ]]; then
wait -n
fi
done
echo ">>> Updating Retweets"
gallery-dl --abort 3 -o retweets=true "https://twitter.com/stefenauris"
gallery-dl --abort 3 -o retweets=true "https://twitter.com/DaybreakHero"
#de-dup?
gallery-dl --abort 3 --sleep 0-1 -o retweets=true "https://twitter.com/stefenauris"
gallery-dl --abort 3 --sleep 0-1 -o retweets=true "https://twitter.com/DaybreakHero"
wait