Shellskript zur Ermittlung der Follower und Formatierung
This commit is contained in:
parent
c6c7f4bb18
commit
0df842c173
1 changed files with 16 additions and 0 deletions
16
get_follower.sh
Normal file
16
get_follower.sh
Normal file
|
@ -0,0 +1,16 @@
|
|||
#!/usr/bin/env sh
|
||||
|
||||
FLIST=Downloads/following-2023-01-01-10-41-58.csv
|
||||
FURL=""
|
||||
FFILE="$(date +%F)"
|
||||
touch $FFILE
|
||||
|
||||
# Preprocessing
|
||||
#echo "qbi@mastodon.social\nmaxschrems@mastodon.social" >> $FLIST
|
||||
sed -i.1 '/@a.gup.pe/d' $FLIST
|
||||
|
||||
while read account; do
|
||||
FURL=$(echo $account | sed 's,^\(.*\)@\(.*\),\2/users/\1/followers,')
|
||||
NFOL=$(curl -Ls -H 'Accept: application/activity+json' $FURL | jq .totalItems)
|
||||
echo "@$account ($NFOL)" >> $FFILE
|
||||
done < $FLIST
|
Loading…
Reference in a new issue