Last active
March 31, 2025 07:08
-
-
Save dominictarr/998a3e6671c44bb18c407f093e525837 to your computer and use it in GitHub Desktop.
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
var pull = require('pull-stream') | |
require('ssb-client')(null, { | |
remote: 'net:wx.larpa.net:8008~shs:DTNmX+4SjsgZ7xyDh5xxmNtFqa6pWi5Qtw7cE8aR9TQ=' | |
}, function (err, sbot) { | |
var start = Date.now(), n = 0; | |
var ts = Date.now() | |
var _n = 0, l = 0, K = 0 | |
var urlEncoded = /([^\n]*(?:%25|%40|%26)[A-Za-z0-9%]+(?:%3D)+\.[A-Za-z0-9]+[^\n]*)/ | |
pull( | |
sbot.createLogStream({}), | |
pull.drain(function (e) { | |
n++; | |
var text = e.value.content.text | |
if(text && urlEncoded.test(text)) { | |
var parts = text.split(urlEncoded).filter(function (e, i) { return (i % 2) }) | |
console.log(parts.join('\n')) | |
if(parts.filter(function (e) { return ~e.indexOf('(') }).length) { | |
K ++ | |
console.log("LINK", parts) | |
} | |
l++ | |
} | |
if(Date.now() - 1000 > ts) { | |
///TOTAL, THIS_SECOND, URL_IDS_FOUND, URL_IDS_INSIDE_LINKS | |
console.error(n, n-_n, l, K) | |
_n = n | |
ts = Date.now() | |
} | |
}, function () { | |
var time = (Date.now() - start)/1000; | |
console.error(time, n/time, l, K) | |
}) | |
) | |
}) | |
The forums you share are really helpful to me, I will follow your posts regularly. For more information about me, go here: foodle
Melon Sandbox is a physics-based, engaging, and entertaining free sandbox game.
sprunki.net started as a fan mod and grew into a full-fledged music game. With diverse characters and original beats, Sprunki is your new go-to platform for music creativity!https://sprunki.net/
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This information is great. geometry dash Just when I needed it