• Posts in the last 24 hours

    From Nelgin@1:103/705 to All on Fri Nov 4 21:01:04 2022
    Hi all,

    I saw on my BBS that some new users have been making posts, but it wasn't very easy to determine where they were posting and what they were dumping on the network.

    I've whipped up a quick script, with the help of Digial Man, that will go through all your message bases and display the messages posted from your BBS in the last 24 hours.

    Download https://www.endofthelinebbs.com/localposts.js.txt and save it as localhosts.js in your /sbbs/mods directory.

    Simply run jsexec localposts

    It will display from, to, subject, date, which echo it was posted in and the message body in plain text with @-codes stripped.

    Please give it a go, let me know if it's useful. Always happy to add enhancements.
    ---
    þ Synchronet þ End Of The Line BBS - endofthelinebbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From deon@1:103/705 to Nelgin on Sat Nov 5 15:33:27 2022
    Re: Posts in the last 24 hours
    By: Nelgin to All on Fri Nov 04 2022 09:01 pm

    Howdy,

    Please give it a go, let me know if it's useful. Always happy to add enhancements.

    This sounds useful - I think it should be included in the git repo...


    ...ëîåï

    ---
    þ Synchronet þ Alterant | an SBBS in Docker on Pi!
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Gamgee@1:103/705 to Nelgin on Sat Nov 5 08:53:00 2022
    Nelgin wrote to All <=-

    I saw on my BBS that some new users have been making posts, but
    it wasn't very easy to determine where they were posting and what
    they were dumping on the network.

    I've whipped up a quick script, with the help of Digial Man, that
    will go through all your message bases and display the messages
    posted from your BBS in the last 24 hours.

    Download https://www.endofthelinebbs.com/localposts.js.txt and
    save it as localhosts.js in your /sbbs/mods directory.

    Simply run jsexec localposts

    It will display from, to, subject, date, which echo it was posted
    in and the message body in plain text with @-codes stripped.

    Please give it a go, let me know if it's useful. Always happy to
    add enhancements.

    Sweet! Seems to work fine here, thanks for doing it!

    One thing I'd like to see - on the "Echo:" line, could that include the
    FTN network name (such as Fido, or FSXnet)? Reason I ask is that
    something like a BBS ad which may get posted to several networks just
    shows up as "BBS Ads" or "BBS Promotion" and it's hard to remember/know
    which network that echo may be in.

    Thanks again.



    ... Strip mining prevents forest fires.
    --- MultiMail/Linux v0.52
    þ Synchronet þ Palantir BBS * palantirbbs.ddns.net * Pensacola, FL
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nightfox@1:103/705 to Nelgin on Sat Nov 5 11:13:21 2022
    Re: Posts in the last 24 hours
    By: Nelgin to All on Fri Nov 04 2022 09:01 pm

    Download https://www.endofthelinebbs.com/localposts.js.txt and save it as localhosts.js in your /sbbs/mods directory.

    I'm curious why you named it .js.txt? It's fairly easy to save (or directly download) a file with a .js filename extension.

    I saw on my BBS that some new users have been making posts, but it wasn't very easy to determine where they were posting and what they were dumping on the network.

    Please give it a go, let me know if it's useful. Always happy to add enhancements.

    It's interesting, but I'm wondering what purpose this is meant to serve? Were you concerned about users posting spam?

    Knowing the purpose of this script would help in thinking of suggestions for enhancements.

    Nightfox

    ---
    þ Synchronet þ Digital Distortion: digitaldistortionbbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nelgin@1:103/705 to All on Sat Nov 5 13:57:24 2022
    On Sat, 5 Nov 2022 08:53:00 -0500
    "Gamgee" <gamgee@VERT/PALANT> wrote:

    Nelgin wrote to All <=-

    I saw on my BBS that some new users have been making posts, but
    it wasn't very easy to determine where they were posting and what
    they were dumping on the network.

    I've whipped up a quick script, with the help of Digial Man, that
    will go through all your message bases and display the messages
    posted from your BBS in the last 24 hours.

    Download https://www.endofthelinebbs.com/localposts.js.txt and
    save it as localhosts.js in your /sbbs/mods directory.

    Simply run jsexec localposts

    It will display from, to, subject, date, which echo it was posted
    in and the message body in plain text with @-codes stripped.

    Please give it a go, let me know if it's useful. Always happy to
    add enhancements.

    Sweet! Seems to work fine here, thanks for doing it!

    One thing I'd like to see - on the "Echo:" line, could that include
    the FTN network name (such as Fido, or FSXnet)? Reason I ask is that something like a BBS ad which may get posted to several networks just
    shows up as "BBS Ads" or "BBS Promotion" and it's hard to
    remember/know which network that echo may be in.

    Sure, no problem. I've added Network:

    From: Nelgin
    To: All
    Subject: Posts in the last 24 hours
    Date: Fri Nov 04 2022 21:01:04 GMT-0500 (CDT)
    Network: DOVE-Net
    Echo: Synchronet Sysops


    Nope that helps. New file is in place.
    --
    End Of The Line BBS - Plano, TX
    telnet endofthelinebbs.com 23
    ---
    þ Synchronet þ End Of The Line BBS - endofthelinebbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nigel Reed@1:124/5016 to deon on Sat Nov 5 16:37:24 2022
    Re: Posts in the last 24 hours
    By: deon to Nelgin on Sat Nov 05 2022 15:33:27

    Please give it a go, let me know if it's useful. Always happy to add enhancements.

    This sounds useful - I think it should be included in the git repo...

    It would probably be more useful if I did an email wrapper or something and had it email the system at midnight for the previous days posts. Maybe someone can add that. :)
    --- SBBSecho 3.15-Linux
    * Origin: End Of The Line BBS - endofthelinebbs.com (1:124/5016)
  • From Nigel Reed@1:124/5016 to Nightfox on Sat Nov 5 16:40:33 2022
    Re: Posts in the last 24 hours
    By: Nightfox to Nelgin on Sat Nov 05 2022 11:13:21

    I'm curious why you named it .js.txt? It's fairly easy to save (or directly download) a file with a .js filename extension.

    Some browsers don't like it for some reason. I had a problem with something or other.

    It's interesting, but I'm wondering what purpose this is meant to serve? Were you concerned about users posting spam?

    I thought I mentioned that but yes. I've had users sign up and post spam in the local groups, which I allow before I verify them (in case of email issues or whatever). I don't allow posting to networked groups now until I increase their privs, but there's still the possiblity of someone going rogue. This will let me check, quickly, what has been posted the previous 24 hours.
    --- SBBSecho 3.15-Linux
    * Origin: End Of The Line BBS - endofthelinebbs.com (1:124/5016)
  • From Digital Man@1:103/705 to Nigel Reed on Sat Nov 5 14:48:47 2022
    Re: Posts in the last 24 hours
    By: Nigel Reed to Nightfox on Sat Nov 05 2022 04:40 pm

    I thought I mentioned that but yes. I've had users sign up and post spam in the local groups, which I allow before I verify them (in case of email issues or whatever). I don't allow posting to networked groups now until I increase their privs, but there's still the possiblity of someone going rogue. This will let me check, quickly, what has been posted the previous 24 hours.

    And if you can't (or forget) to check one day, is your script flexible enough to go back 2 or more days?
    --
    digital man (rob)

    Rush quote #68:
    He's a radio receiver, tuned to factories and farms .. New World Man
    Norco, CA WX: 71.4øF, 29.0% humidity, 4 mph ESE wind, 0.00 inches rain/24hrs --- SBBSecho 3.15-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nelgin@1:103/705 to Digital Man on Sat Nov 5 17:06:11 2022
    Re: Posts in the last 24 hours
    By: Digital Man to Nigel Reed on Sat Nov 05 2022 14:48:47

    And if you can't (or forget) to check one day, is your script flexible enough to go back 2 or more days?

    // This is the number of seconds we're going to look back for messages. Time is in miliseconds
    // the default is 24 hours.

    const duration=24*60*60*1000


    Just change 24 to 48 or or how many hours you wish to go back.
    ---
    þ Synchronet þ End Of The Line BBS - endofthelinebbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Digital Man@1:103/705 to Nelgin on Sat Nov 5 15:25:16 2022
    Re: Posts in the last 24 hours
    By: Nelgin to Digital Man on Sat Nov 05 2022 05:06 pm

    Re: Posts in the last 24 hours
    By: Digital Man to Nigel Reed on Sat Nov 05 2022 14:48:47

    And if you can't (or forget) to check one day, is your script flexible enough to go back 2 or more days?

    // This is the number of seconds we're going to look back for messages. Time is in miliseconds
    // the default is 24 hours.

    const duration=24*60*60*1000


    Just change 24 to 48 or or how many hours you wish to go back.

    Or accept the number of days as a command-line option?

    Or store the date/time last scanned and use that date/time as the threshold to scan/display (and update it when after each) - like a new message scan pointer.
    --
    digital man (rob)

    Breaking Bad quote #22:
    I got one more shot at that little skid mark. - Hank Schrader
    Norco, CA WX: 71.0øF, 29.0% humidity, 5 mph E wind, 0.00 inches rain/24hrs
    --- SBBSecho 3.15-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nelgin@1:103/705 to Digital Man on Sun Nov 6 01:07:43 2022
    Re: Posts in the last 24 hours
    By: Digital Man to Nelgin on Sat Nov 05 2022 15:25:16

    Just change 24 to 48 or or how many hours you wish to go back.

    Or accept the number of days as a command-line option?

    I think you got me mistaken for someone who knows how to do stuff :)
    ---
    þ Synchronet þ End Of The Line BBS - endofthelinebbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nightfox@1:103/705 to Nelgin on Mon Nov 7 09:55:41 2022
    Re: Posts in the last 24 hours
    By: Nelgin to Digital Man on Sun Nov 06 2022 01:07 am

    Or accept the number of days as a command-line option?

    I think you got me mistaken for someone who knows how to do stuff :)

    There's a global property called argv which contains command-line arguments that you could check.
    It's mentioned under "global properties" in the JS documentation: http://www.synchro.net/docs/jsobjs.html

    Nightfox

    ---
    þ Synchronet þ Digital Distortion: digitaldistortionbbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nelgin@1:103/705 to Nightfox on Mon Nov 7 13:41:49 2022
    Re: Posts in the last 24 hours
    By: Nightfox to Nelgin on Mon Nov 07 2022 09:55:41

    There's a global property called argv which contains command-line arguments

    Pretty much every language has an arvg ;)

    and yes, I did this before I read your post.

    You can now pass a numerical argument and it'll use that for the number of hours.

    jsexec localposts.js 6

    Will look back just 6 hours

    jsexec localposts.js 168

    Will go back a whole week.

    I've only done basic testing, but it should fail on anything that's not a number and default to 24 hours.

    Latest version is now at:

    https://www.endofthelinebbs.com/localposts.js.txt

    Dump it in your mods as localposts.js
    ---
    þ Synchronet þ End Of The Line BBS - endofthelinebbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Gamgee@1:103/705 to Nelgin on Mon Nov 7 14:55:00 2022
    Nelgin wrote to Nightfox <=-

    Re: Posts in the last 24 hours
    By: Nightfox to Nelgin on Mon Nov 07 2022 09:55:41

    There's a global property called argv which contains command-line arguments

    Pretty much every language has an arvg ;)

    and yes, I did this before I read your post.

    You can now pass a numerical argument and it'll use that for the
    number of hours.

    jsexec localposts.js 6

    Will look back just 6 hours

    jsexec localposts.js 168

    Will go back a whole week.

    I've only done basic testing, but it should fail on anything
    that's not a number and default to 24 hours.

    Latest version is now at:

    https://www.endofthelinebbs.com/localposts.js.txt

    Dump it in your mods as localposts.js


    I'm getting no output from the script if I put any number on the command
    line. With no number argument it works (last 24 hours). Here's an
    example:

    danc@palantir:/sbbs/mods$ ../exec/jsexec localposts 6

    JSexec v3.19c-Linux master/25b0e6d73 - Execute Synchronet JavaScript Module Compiled Oct 22 2022 08:37:08 with GCC 11.2.0

    Loading configuration files from /sbbs/ctrl
    JavaScript-C 1.8.5 2011-03-31
    JavaScript: Creating runtime: 16777216 bytes

    Reading script from /sbbs/mods/localposts.js
    /sbbs/mods/localposts.js compiled in 0.00 seconds
    /sbbs/mods/localposts.js executed in 3.71 seconds

    JavaScript: Destroying context
    JavaScript: Destroying runtime
    danc@palantir:/sbbs/mods$


    ... Internal Error: The system has been taken over by sheep at line 19960
    --- MultiMail/Linux v0.52
    þ Synchronet þ Palantir BBS * palantirbbs.ddns.net * Pensacola, FL
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nelgin@1:103/705 to Gamgee on Mon Nov 7 21:47:53 2022
    Re: Re: Posts in the last 24 hours
    By: Gamgee to Nelgin on Mon Nov 07 2022 14:55:00

    I'm getting no output from the script if I put any number on the command line. With no number argument it works (last 24 hours). Here's an
    example:

    I see the problem.

    Change

    var duration=argv[0]*60*60*100;
    to
    var duration=argv[0]*60*60*1000;

    I missed a 0.

    Thanks for the report.
    ---
    þ Synchronet þ End Of The Line BBS - endofthelinebbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Gamgee@1:103/705 to Nelgin on Tue Nov 8 07:26:00 2022
    Nelgin wrote to Gamgee <=-

    Re: Re: Posts in the last 24 hours
    By: Gamgee to Nelgin on Mon Nov 07 2022 14:55:00

    I'm getting no output from the script if I put any number on the command line. With no number argument it works (last 24 hours). Here's an
    example:

    I see the problem.

    Change

    var duration=argv[0]*60*60*100;
    to
    var duration=argv[0]*60*60*1000;

    I missed a 0.

    Thanks for the report.

    Got it, thanks. I really do find this useful.



    ... Computer Hacker wanted. Must have own axe.
    --- MultiMail/Linux v0.52
    þ Synchronet þ Palantir BBS * palantirbbs.ddns.net * Pensacola, FL
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nelgin@1:103/705 to Gamgee on Tue Nov 8 10:08:19 2022
    Re: Re: Posts in the last 24 hours
    By: Gamgee to Nelgin on Tue Nov 08 2022 07:26:00

    Got it, thanks. I really do find this useful.

    Maybe I don't give myself enough credit :)
    ---
    þ Synchronet þ End Of The Line BBS - endofthelinebbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Max@1:103/705 to Nelgin on Wed Nov 9 17:12:08 2022
    RE: Posts in the last 24 hours
    BY: Nelgin to All on Fri Nov 04 2022 21:01:04

    Simply run jsexec localposts

    Not working here in 3.20a:

    Reading script from S:\sbbs\exec\mods\localposts.js S:\sbbs\exec\mods\localposts.js compiled in 0.00 seconds
    !JavaScript S:\sbbs\exec\mods\localposts.js line 56: TypeError: msg is null S:\sbbs\exec\mods\localposts.js executed in 8.11 seconds
    !Module (localposts) set exit_code: 1

    What's wrong?

    /Max

    ---
    þ Synchronet þ Pepzi - Pepzi.se - 1000/1000 MBits
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nelgin@1:103/705 to Max on Wed Nov 9 16:25:52 2022
    Re: Posts in the last 24 hours
    By: Max to Nelgin on Wed Nov 09 2022 17:12:08

    Not working here in 3.20a:
    What's wrong?

    No idea. Fun stuff keeps coming up like posts that are votes I filter out. There must be something else. I'll see if it happens on my board and if not then I'll maybe ask you to download a version with some debugging so I can tell what the problem is. This will probably be tomorrow.

    Thanks for letting me know about the issue.
    ---
    þ Synchronet þ End Of The Line BBS - endofthelinebbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)