• Single key to switch comm

    From Razor@VERT/SILENT to All on Sun Feb 28 03:47:00 2010
    I'd like to "quit" from my custom shell back to the "default" shell. What I'm doing so far doesn't seem to change the user config option for command shell & disconnects me from telnet. Here's my current code:
    case 'Q':
    user.command_shell="DEFAULT";
    exit(0);

    Does anyone see an obvious error in my logic? This is similar to code used for changing shells through the user config editor.


    ---
    þ Synchronet þ The Silent Strike - bbs.thesilentstrike.com
  • From Digital Man@VERT to Razor on Sun Feb 28 12:25:00 2010
    Re: Single key to switch command shells?
    By: Razor to All on Sun Feb 28 2010 08:47 am

    I'd like to "quit" from my custom shell back to the "default" shell. What I'm doing so far doesn't seem to change the user config option for command shell & disconnects me from telnet. Here's my current code:
    case 'Q':
    user.command_shell="DEFAULT";
    exit(0);

    Does anyone see an obvious error in my logic?

    The setting of the command shell looks correct, but I don't understand the use of exit(). Shells are not normally "nested". An exit() would just stop the shell.

    digital man

    Snapple "Real Fact" #77:
    No piece of paper can be folded more than 7 times.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Razor@VERT/SILENT to Digital Man on Sun Feb 28 17:09:00 2010
    Re: Single key to switch command shells?
    By: Digital Man to Razor on Sun Feb 28 2010 05:25 pm

    Re: Single key to switch command shells?
    By: Razor to All on Sun Feb 28 2010 08:47 am
    I'd like to "quit" from my custom shell back to the "default" shell.
    case 'Q':
    user.command_shell="DEFAULT";
    exit(0);
    The setting of the command shell looks correct, but I don't understand the use of exit(). Shells are not normally "nested". An exit() would just stop the shell.

    Ahh, I was never executing the new shell. I still don't quite have it, but I might come back to that later.
    Now I'm trying to choose a shell from logon.js & no matter which I choose, I always get DEFAULT. Here's my code for that.

    if(!console.noyes("Quick logon"))
    {
    user.command_shell="RQSHELL";
    }
    else
    {
    user.command_shell="DEFAULT";
    }



    ---
    þ Synchronet þ The Silent Strike - bbs.thesilentstrike.com
  • From Digital Man@VERT to Razor on Sun Feb 28 18:04:00 2010
    Re: Single key to switch command shells?
    By: Razor to Digital Man on Sun Feb 28 2010 10:09 pm

    Re: Single key to switch command shells?
    By: Digital Man to Razor on Sun Feb 28 2010 05:25 pm

    Re: Single key to switch command shells?
    By: Razor to All on Sun Feb 28 2010 08:47 am
    I'd like to "quit" from my custom shell back to the "default" shell. case 'Q':
    user.command_shell="DEFAULT";
    exit(0);
    The setting of the command shell looks correct, but I don't understand the use of exit(). Shells are not normally "nested". An exit() would
    just stop the shell.

    Ahh, I was never executing the new shell. I still don't quite have it, but I might come back to that later.
    Now I'm trying to choose a shell from logon.js & no matter which I choose,
    I always get DEFAULT. Here's my code for that.

    if(!console.noyes("Quick logon"))
    {
    user.command_shell="RQSHELL";
    }
    else
    {
    user.command_shell="DEFAULT";
    }

    You discovered a bug with the Synchronet JS "User" class, which I just fixed. When setting the command_shell property, it was writing to the host_name / computer property instead. If you get tonight's development build (dated mar-1) this should be fixed.

    digital man

    Snapple "Real Fact" #158:
    The first MTV video was "Video Killed the Radio Star," by the Buggles.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Razor@VERT/SILENT to Digital Man on Mon Mar 1 06:25:00 2010
    Re: Single key to switch command shells?
    By: Digital Man to Razor on Sun Feb 28 2010 11:04 pm

    You discovered a bug with the Synchronet JS "User" class, which I just fixed. When setting the command_shell property, it was writing to the host_name / computer property instead. If you get tonight's development build (dated mar-1) this should be fixed.

    Very cool, thanks DM.


    ---
    þ Synchronet þ The Silent Strike - bbs.thesilentstrike.com