• Coding shell switching into a shell

    From Khelair@VERT/TINFOIL to All on Fri Jan 23 22:43:20 2015
    Hey, I asked a few times in Synchronet IRC, but I do believe that people wereãtoo busy for quasi-synchronous communication at the time, so I figured I'd postãhere a little bit about it.ã I'm still working on development of the same shell that I was previously. ãThe last real step I need to finish before I roll it out for alpha/beta peopleãto start peeking at is being able to let them switch back from that shell toãsomething else when they find areas that it's helplessly broken, and when theyãwant to access functionality that I simply don't have coded in yet...ã So I started using bbs.select_shell(). Now I just realized that part of theãproblem might be that I'm currently debugging it as a door, and not as a shell,ãso let me know if that's my primary fubar and I'll just shut up and slink away.ã*grin*ã Anyway, I realized that after pulling up the correct routine for selecting aãnew shell, I'm still stuck in my code. Is that something where I need toãactively search out the shell that I've switched to, clean up my shell'sãenvironment, and jump to that code? The other 'shell' methods that I've seenãdon't seem to have anything to do with activating a new shell. I just don'tãwant users to have to log out and log back in in order to get to the new shell.ã Like I said, I'm having an inkling now that this might just be due to theãfact that I'm debugging it as a door; if so, sorry to waste your time, but feelãfree to poke fun of me a bit! :)ãã---ã þ Synchronet þ Tinfoil Tetrahedron BBS telnet://tinfoil.synchro.netã
  • From Nightfox@VERT/DIGDIST to Khelair on Sun Jan 25 08:50:29 2015
    Re: Coding shell switching into a shellã By: Khelair to All on Fri Jan 23 2015 22:43:20ãã Kh> So I started using bbs.select_shell(). Now I just realized that part ofã Kh> the problem might be that I'm currently debugging it as a door, and not asã Kh> a shell, so let me know if that's my primary fubar and I'll just shut upã Kh> and slink away. *grin*ããYou should probably debug it with it set up as a shell rather than a door.ãã Kh> Anyway, I realized that after pulling up the correct routine for selectingã Kh> a new shell, I'm still stuck in my code. Is that something where I need toã Kh> actively search out the shell that I've switched to, clean up my shell'sã Kh> environment, and jump to that code? The other 'shell' methods that I'veããAfter running bbs.select_shell(), your shell might need to exit. I haven'tãtried using bbs.select_shell(), but in my shell I have a section where I callãbbs.user_config() to let the user change their configuration options. Afterãdoing so, I check whether user.command_shell has changed, and if so, my shellãcalls exit(0); so that it will exit, then it drops the user into their newãshell. I do a few other things around there, which may or may not be necessaryã(I may have seen these in other shells):ããvar oldShell = user.command_shell;ãbbs.user_config();ãuser.cached = false;ãbbs.user_sync();ã// If the user has chosen a different command shell, then exitã// out of this one.ãif (user.command_shell != oldShell)ã exit(0);ããNightfoxãã---ã þ Synchronet þ Digital Distortion BBS - digitaldistortionbbs.comã
  • From Khelair@VERT/TINFOIL to Nightfox on Sun Jan 25 13:55:04 2015
    Re: Coding shell switching into a shellã By: Nightfox to Khelair on Sun Jan 25 2015 08:50:29ãã > You should probably debug it with it set up as a shell rather than a door.ã > ã > Kh> Anyway, I realized that after pulling up the correct routine for selectã > Kh> a new shell, I'm still stuck in my code. Is that something where I needã > Kh> actively search out the shell that I've switched to, clean up my shell'ã > Kh> environment, and jump to that code? The other 'shell' methods that I'veã > ã > After running bbs.select_shell(), your shell might need to exit. I haven'tã > tried using bbs.select_shell(), but in my shell I have a section where I calã > bbs.user_config() to let the user change their configuration options. Afterã > doing so, I check whether user.command_shell has changed, and if so, my shelã > calls exit(0); so that it will exit, then it drops the user into their newã > shell. I do a few other things around there, which may or may not be necessãã Yeah, turns out that that's what did it. Works in both versions (door andãshell), but since I'm so close to alpha testing this I just decided to startãtesting exclusively in shell mode.ãã-=-ãBorg Burger: We do it our way; your way is irrelevant.ãã---ã þ Synchronet þ Tinfoil Tetrahedron BBS telnet://tinfoil.synchro.netã
  • From Digital Man@VERT to Khelair on Mon Jan 26 01:57:51 2015
    Re: Coding shell switching into a shellã By: Khelair to Nightfox on Sun Jan 25 2015 01:55 pmãã > Re: Coding shell switching into a shellã > By: Nightfox to Khelair on Sun Jan 25 2015 08:50:29ã >ã > > You should probably debug it with it set up as a shell rather than aã > > door.ã > >ã > > Kh> Anyway, I realized that after pulling up the correct routine forã > > Kh> select a new shell, I'm still stuck in my code. Is that somethingã > > Kh> where I need actively search out the shell that I've switched to,ã > > Kh> clean up my shell' environment, and jump to that code? The otherã > > Kh> 'shell' methods that I'veã > >ã > > After running bbs.select_shell(), your shell might need to exit. Iã > > haven't tried using bbs.select_shell(), but in my shell I have a sectionã > > where I cal bbs.user_config() to let the user change their configurationã > > options. After doing so, I check whether user.command_shell hasã > > changed, and if so, my shel calls exit(0); so that it will exit, then itã > > drops the user into their new shell. I do a few other things aroundã > > there, which may or may not be necessã >ã > Yeah, turns out that that's what did it. Works in both versions (doorã > and shell), but since I'm so close to alpha testing this I just decided toã > start testing exclusively in shell mode.ããCheckout exec/lbshell.js. It allows you to select/change shells dynamically.ãã digital manããSynchronet "Real Fact" #55:ãSynchronet Terminal Server introduced SecureShell (SSH) support w/v3.14a (2006).ãNorco, CA WX: 65.3øF, 29.0% humidity, 5 mph NNW wind, 0.00 inches rain/24hrsã---ã þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.netã
  • From Khelair@VERT/TINFOIL to Digital Man on Mon Jan 26 06:29:00 2015
    Re: Coding shell switching into a shellã By: Digital Man to Khelair on Mon Jan 26 2015 01:57:51ãã DM> Checkout exec/lbshell.js. It allows you to select/change shellsã DM> dynamically.ãã Wilco. Thnx.ãã-=-ãBorg Burger: We do it our way; your way is irrelevant.ãã---ã þ Synchronet þ Tinfoil Tetrahedron BBS telnet://tinfoil.synchro.netã