• Running doors from anywhere?

    From Divarin@1:103/705 to All on Wed Nov 3 08:45:05 2021
    Is it possible to run a door from anywhere on a Synchronet BBS?
    For example I'd like to have certain doors executable straight from the main menu and there's one I'd like to be executable from the Text Files menu. Short of digging into the source code and recompiling is this doable?

    ---
    þ Synchronet þ Mutiny BBS - mutinybbs.com - telnet:2332 - ssh:2232
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nightfox@1:103/705 to Divarin on Wed Nov 3 09:13:03 2021
    Re: Running doors from anywhere?
    By: Divarin to All on Wed Nov 03 2021 08:45 am

    Is it possible to run a door from anywhere on a Synchronet BBS?
    For example I'd like to have certain doors executable straight from the main menu and there's one I'd like to be executable from the Text Files menu. Short of digging into the source code and recompiling is this doable?

    Yes, you'd need to modify your command shell to add an option to those menus. It's fairly easy to do.
    If you're using the default command shell, it's written in Baja. Under the sections for those menus, you'd need to add an option and have it call EXEC_XTRN with the internal code of the door you want to run. Refer to the Synchronet Baja guide:
    http://synchro.net/docs/baja.html

    Also, some more information about Synchronet command shells: http://wiki.synchro.net/custom:command_shell

    There is a JavaScript equivalent to that as well, though I think it's probably more likely your command shell is written in Baja.

    Nightfox

    ---
    þ Synchronet þ Digital Distortion: digitaldistortionbbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Divarin@1:103/705 to Nightfox on Thu Nov 4 07:31:39 2021
    Re: Running doors from anywhere?
    By: Nightfox to Divarin on Wed Nov 03 2021 09:13:03

    Yes, you'd need to modify your command shell to add an option to those menus If you're using the default command shell, it's written in Baja. Under the http://synchro.net/docs/baja.html

    Hmm. okay yeah I was looking at that.
    Here's a specific example of what I'm trying to do: I have a door I wrote which uses gopher to allow users to browse / read the text files from Jason Scott's TextFiles.com (using the gopher mirror)
    I'd like to have this door listed under the text files menu rather than the (X) external programs menu.
    In the default.src file I see the option to access the text file section:

    cmdkey G
    text_file_section
    end_cmd

    But I don't see a source file for the text file section itself.
    Unfortunately the wiki page "Customizing with Baja" doesn't exist I clicked the link and it game up with a "This topic does not exist yet" page.

    ---
    þ Synchronet þ Mutiny BBS - mutinybbs.com - telnet:2332 - ssh:2232
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Nightfox@1:103/705 to Divarin on Thu Nov 4 08:37:59 2021
    Re: Running doors from anywhere?
    By: Divarin to Nightfox on Thu Nov 04 2021 07:31 am

    Yes, you'd need to modify your command shell to add an option to those
    menus If you're using the default command shell, it's written in Baja.
    Under the http://synchro.net/docs/baja.html

    Hmm. okay yeah I was looking at that.
    Here's a specific example of what I'm trying to do: I have a door I wrote which uses gopher to allow users to browse / read the text files from Jason Scott's TextFiles.com (using the gopher mirror)
    I'd like to have this door listed under the text files menu rather than the (X) external programs menu.
    In the default.src file I see the option to access the text file section:

    cmdkey G
    text_file_section
    end_cmd

    But I don't see a source file for the text file section itself. Unfortunately the wiki page "Customizing with Baja" doesn't exist I clicked the link and it game up with a "This topic does not exist yet" page.

    I'm not as familiar with the text files section, but there's a JavaScript script called text_sec.js which I believe is the script that handles displaying the text section. You probably wouldn't want to modify that, as I'm pretty sure it's supposed to be a generic script that builds a menu of text files you have to allow the user to choose and display one.

    I'd like to have this door listed under the text files menu rather than the (X) external programs menu.

    I think that may actually be more difficult to do. If you want to do that, then you'd have to manually generate a drop file and then build a command line to run the door, etc.. The easiest way would be to configure the door as an external program in SCFG and then use EXEC_XTRN command to run it from the command shell. Then Synchronet would take care of the drop file, FOSSIL driver (if needed) and everything to run the door.

    Nightfox

    ---
    þ Synchronet þ Digital Distortion: digitaldistortionbbs.com
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Digital Man@1:103/705 to Divarin on Thu Nov 4 14:20:50 2021
    Re: Running doors from anywhere?
    By: Divarin to Nightfox on Thu Nov 04 2021 07:31 am

    Re: Running doors from anywhere?
    By: Nightfox to Divarin on Wed Nov 03 2021 09:13:03

    Yes, you'd need to modify your command shell to add an option to those menus If you're using the default command shell, it's written in Baja. Under the http://synchro.net/docs/baja.html

    Hmm. okay yeah I was looking at that.
    Here's a specific example of what I'm trying to do: I have a door I wrote which uses gopher to allow users to browse / read the text files from Jason Scott's TextFiles.com (using the gopher mirror)
    I'd like to have this door listed under the text files menu rather than the (X) external programs menu.
    In the default.src file I see the option to access the text file section:

    cmdkey G
    text_file_section
    end_cmd

    But I don't see a source file for the text file section itself.

    Just replace "text_file_section" with "exec_xtrn gopher" (replace "gopher" with the internal code of your configured external program you want to run). Then recompile the command shell .src (to .bin) using 'baja'.

    Unfortunately the wiki page "Customizing with Baja" doesn't exist I clicked the link and it game up with a "This topic does not exist yet" page.

    Is there a reference to "Customizing with Baja" in the wiki?
    --
    digital man

    Synchronet/BBS Terminology Definition #78:
    SyncTERM = The Synchronet Terminal Emulator/BBS-client program
    Norco, CA WX: 81.2øF, 38.0% humidity, 8 mph NNW wind, 0.00 inches rain/24hrs --- SBBSecho 3.14-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Divarin@1:103/705 to Digital Man on Fri Nov 5 06:05:29 2021
    Re: Running doors from anywhere?
    By: Digital Man to Divarin on Thu Nov 04 2021 14:20:50

    Just replace "text_file_section" with "exec_xtrn gopher" (replace "gopher" w

    Hmm okay that would work except that I have other text files in the text files section I want listed as well. basically I want the text files section to work as is now but also have an extra option for accessing the door.

    I'll take a look at the javascript file and see if I can do something in there.

    ---
    þ Synchronet þ Mutiny BBS - mutinybbs.com - telnet:2332 - ssh:2232
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Digital Man@1:103/705 to Divarin on Sat Nov 6 12:00:26 2021
    Re: Running doors from anywhere?
    By: Divarin to Digital Man on Fri Nov 05 2021 06:05 am

    Re: Running doors from anywhere?
    By: Digital Man to Divarin on Thu Nov 04 2021 14:20:50

    Just replace "text_file_section" with "exec_xtrn gopher" (replace "gopher" w

    Hmm okay that would work except that I have other text files in the text files section I want listed as well. basically I want the text files section to work as is now but also have an extra option for accessing the door.

    I'll take a look at the javascript file and see if I can do something in there.

    Yeah, the JavaScript file of interest would be exec/text_sec.js. You could add a bbs.exec_xtrn('gopher') call in there somewhere in response to a special key-press I suppose.
    --
    digital man

    Synchronet/BBS Terminology Definition #16:
    CR = Carriage Return (ASCII 13, Ctrl-M)
    Norco, CA WX: 62.8øF, 90.0% humidity, 2 mph W wind, 0.00 inches rain/24hrs
    --- SBBSecho 3.14-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)