Created
June 10, 2024 23:19
-
-
Save IngwiePhoenix/4af8d64111e6b644b10ef41ebf3efada to your computer and use it in GitHub Desktop.
Kills a nostr note, hopefuly.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh -x | |
# Install fiatjaf/nak (go), htmlq (rust) and jq (go) first. | |
# Set these | |
NSEC= | |
NEVENT= | |
del_notes() { | |
P=$(mktemp) | |
curl "$1" | jq -r '. | join("\n")' > $P | |
while read line; do | |
nak event -k 5 -e $NEVENT --sec $NSEC "$line" & | |
done < $P | |
wait | |
} | |
del_xport() { | |
P=$(mktemp) | |
curl https://relays.xport.top | htmlq -t "body > main > table > tbody > tr > td:nth-child(1)" > $P | |
while read line; do | |
nak event -k 5 -e $NEVENT --sec $NSEC "$line" & | |
done < $P | |
wait | |
} | |
del_notes "https://api.nostr.watch/v1/nip/5" | |
del_notes "https://api.nostr.watch/v1/nip/1" | |
del_notes "https://api.nostr.watch/v1/public" | |
del_notes "https://api.nostr.watch/v1/online" | |
del_xport |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment