1
0
Fork 0

Small auction tracker script

This commit is contained in:
Teo-CD 2022-04-18 10:49:25 +01:00
parent 3c15c5a9f5
commit 64a678b53b

12
Perso/auction_tracker.sh Executable file
View file

@ -0,0 +1,12 @@
#!/bin/bash
if [ $# -ne 1 ]; then
echo "Usage : ./auction_tracker.sh \"search terms\""
exit -1
fi
result=$(curl -s https://www.bidspotter.co.uk/en-gb/search-results?searchTerm="$1" | rg -e "<h1>.*</h1>" | rg -oe "([1-9]+[0-9]*) item\(s\)")
if [ "$result" ]; then
notify-send "Number of $1 listings : $result"
fi