home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / os / vxworks / 1152 < prev    next >
Encoding:
Internet Message Format  |  1992-12-23  |  2.0 KB

  1. Path: sparky!uunet!spool.mu.edu!agate!dog.ee.lbl.gov!lbl.gov!vxwexplo
  2. From: bgeer@beorn.sim.es.com (bob geer)
  3. Newsgroups: comp.os.vxworks
  4. Subject: shell input line editor
  5. Date: Wed, 23 Dec 92 15:15:25 MST
  6. Organization: Lawrence Berkeley Laboratory, Berkeley CA
  7. Lines: 36
  8. Sender: vxwexplo@lbl.gov
  9. Message-ID: <9212232215.AA11226@beorn>
  10. NNTP-Posting-Host: 128.3.112.16
  11. Originator: daemon@vxw.ee.lbl.gov
  12.  
  13. I don't much like the vi-like "led" line editor that comes with
  14. VxWorks & I would like to replace it with a friendlier one that knows
  15. about cursor & function keys & can be user configured.  I have the
  16. input & editing code already running to my satisfaction as a
  17. standalone & now I'm trying to put in between the terminal input & the
  18. shell by creating a /pty/ pseudo-terminal device & redirecting shell's
  19. input by changing it's STD_IN fd.  Not having a lot of luck, tho.
  20.  
  21. In particular, my routine echos all the input, & the shell insists on
  22. echoing it as well after it's received from the /pty/slave device.
  23.  
  24. My routine expects unquoted string input & assumes the user wants
  25. strings to be quoted.  An input token that doesn't start with a digit
  26. is considered a string & is quoted by my routine, a token that starts
  27. with a digit is not quoted -- this is satisfactory for my current
  28. needs.  However, the quotes disappear somewhere after being written to
  29. the /pty/master; double quoting on each end of the token seems to
  30. preserve a single set of quotes thru to the shell.
  31.  
  32. So far, my experience trying to figure out how to accomplish what
  33. should be a straightforward task using the distributed documentation
  34. is sure taking a long time.  Both the telnet & rlogin daemons do this
  35. somehow; unfortunately that source code isn't included as an example.
  36.  
  37. Yes, I am RFM & RFMan pages.
  38.  
  39. I would appreciate any info & suggestions anyone had regarding this
  40. problem.  In particular:
  41.  
  42. 1)  Is the pseudo-terminal method a reasonable way to do this?
  43.  
  44. 2)  Describe a better way to do this.
  45.  
  46. 3)  Example code would be appreciated.
  47.  
  48. Thanks in advance...Bob
  49.