home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / next / sysadmin / 4411 < prev    next >
Encoding:
Text File  |  1992-07-27  |  2.1 KB  |  66 lines

  1. Newsgroups: comp.sys.next.sysadmin
  2. Path: sparky!uunet!stanford.edu!leland.Stanford.EDU!news
  3. From: magnus@Fisher.Stanford.EDU (Magnus Nordborg)
  4. Subject: Re: Emacs environment variable lost
  5. Message-ID: <1992Jul27.235900.10468@leland.Stanford.EDU>
  6. Sender: news@leland.Stanford.EDU (Mr News)
  7. Organization: DSO, Stanford University
  8. References: <1992Jul24.145633.28258@cs.sfu.ca>
  9. Distribution: cct
  10. Date: Mon, 27 Jul 92 23:59:00 GMT
  11. Lines: 53
  12.  
  13. In article <1992Jul24.145633.28258@cs.sfu.ca> patrice@cs.sfu.ca (Patrice  
  14. Belleville) writes:
  15. > From article <CMOORE.92Jul24092902@zenobia.mit.edu>, by  
  16. cmoore@zenobia.mit.edu (Christopher B. Moore):
  17. > > 
  18. > > I've noticed (while installing the Auc-TeX package) that evaluation of
  19. > > (getenv "HOSTTYPE") in an Emacs2.1 window started by clicking on the
  20. > > Emacs2.1 icon in the workspace returns nil.  However, in an Emacs2.1
  21. > > window started from the commandline it returns "next".  What gives?
  22. > > 
  23. > > Christopher B. Moore
  24. > > cmoore@maggie.mit.edu
  25. >     Well, the problem is that the  workspace does not  run your .login  
  26. or
  27. > your .cshrc.   So programs  started from it  will not  have access  to    
  28. your
  29. > favorite environment variables. One fix is to add the following lines to  
  30. your
  31. > ..emacs file:
  32. > (setq process-environment (append
  33. >         process-environment
  34. >     '("HOSTTYPE=next" "OTHERVAR=othervalue" [more of these])))
  35. > -- 
  36. >  
  37. /************************************************************************* 
  38. **\
  39. > |* Patrice Belleville                       
  40. patrice@cs.sfu.ca *|
  41. > |*   --- Simon Fraser University is not responsible for my mistakes. ---    
  42. *|
  43. >  
  44. \************************************************************************* 
  45. **/
  46.  
  47. This only fixes some problems -- the *best* solution has been posted here  
  48. before and is to rename emacs to (say) real_emacs and then write a script  
  49. called emacs with the following content (replace tcsh with your favorite):
  50.  
  51. #!/usr/local/bin/tcsh
  52. /usr/bin/real_emacs $1
  53.  
  54. --
  55.  
  56.  
  57.         Magnus Nordborg
  58.         Department of Biological Sciences
  59.         Stanford University
  60.         magnus@fisher.stanford.edu (NeXT mail preferred)
  61.