home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / graphics / gnuplot / 329 < prev    next >
Encoding:
Text File  |  1992-11-09  |  2.6 KB  |  61 lines

  1. Newsgroups: comp.graphics.gnuplot
  2. Path: sparky!uunet!haven.umd.edu!darwin.sura.net!jvnc.net!gmd.de!ira.uka.de!Sirius.dfn.de!math.fu-berlin.de!news.th-darmstadt.de!alexlehm
  3. From: alexlehm@iti.informatik.th-darmstadt.de (Alexander Lehmann)
  4. Subject: Re: Comment on GnuPlot V3.2 (under Unix)
  5. Sender: news@news.th-darmstadt.de (The News System)
  6. Message-ID: <1992Nov9.133540.56395@news.th-darmstadt.de>
  7. Date: Mon, 9 Nov 1992 13:35:40 GMT
  8. References: <1992Nov5.194056@helix.nih.gov>
  9. Nntp-Posting-Host: sun4.iti.informatik.th-darmstadt.de
  10. Organization: TH Darmstadt
  11. Lines: 48
  12.  
  13. rvenable@helix.nih.gov (Richard M. Venable) writes:
  14. > In article <921105105653.1747@CUCCFA.CCC.COLUMBIA.EDU>,
  15. > MARK@CUCCFA.CCC.COLUMBIA.EDU (T. Mark Reboul) writes:
  16. > |> I have however noted just one minor thing which seems to me like a 
  17. > |> deficiency.... I don't know how easy this would be to change, but it
  18. > |> would be useful if the user could enter a "cd" command of the form:
  19. > |> 
  20. > |>     cd  "~username/whatever"
  21. > |> 
  22. > |> The tilde spec doesn't seem to be allowed. (Am I doing something
  23. > wrong?)
  24. > The tilde is a construct of the C shell (/bin/csh), and is not
  25. > recognized
  26. > by system calls requiring a pathname.  In some of our programs here at
  27. > NIH
  28. > we substitute the value of the env var HOME for the tilde, which would
  29. > permit   cd "~/whatever"  but not the above syntax.
  30.  
  31. There are a couple of unix programs that emulate the behaviour of the csh
  32. ~user prefix. It should be not that difficult to include that feature into
  33. gnuplot for the unix version. There are however some problems finding the
  34. passwd entries for different types of systems e.g. with NIS.
  35. Since gnuplot 3.3 has just moved into beta stage, this will have to be
  36. considered for 3.4, but I try to keep the suggestion in mind.
  37.  
  38. > |> I also noticed that even this command:
  39. > |> 
  40. > |>     !  cd  ~username
  41. > |> 
  42. > |> doesn't work, as the "system" function call generated by my command 
  43. > |> won't handle the tilde.
  44. > The above should work if /bin/csh is your login shell; however, the !
  45. > operation spawns a new subshell, so that even if you do change
  46. > directories,
  47. > as soon as the subshell exits, you're back in the directory you were in
  48. > before.
  49.  
  50. The problem with the above command is the following. If you shell is csh,
  51. the cd command will be executed correctly, but since the new csh is started as
  52. a childprocess, the changes in the csh will not affect the setting in gnuplot.
  53. That is any cd command will fail is executed by ! (as do setenvs).
  54.  
  55. -- 
  56. Alexander Lehmann                      | "Wopp"
  57. alexlehm@iti.informatik.th-darmstadt.de|         -  ( THHGTTG Pt.3 )
  58.