home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / emacs / 3855 < prev    next >
Encoding:
Text File  |  1992-12-23  |  3.5 KB  |  66 lines

  1. Xref: sparky comp.emacs:3855 gnu.emacs.help:5166
  2. Newsgroups: comp.emacs,gnu.emacs.help
  3. Path: sparky!uunet!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!uchinews!lucpum.it.luc.edu!lucpul.it.luc.edu!eneafsey
  4. From: eneafsey@lucpul.it.luc.edu (E. J. Neafsey)
  5. Subject: demacs, file locking, set TZ=CST-9
  6. Message-ID: <eneafsey.725114716@lucpul.it.luc.edu>
  7. Summary: observations on demacs's file locking problems and set TZ
  8. Keywords: demacs
  9. Sender: root@lucpum.it.luc.edu (System PRIVILEGED Account)
  10. Organization: Loyola University Chicago
  11. Date: Wed, 23 Dec 1992 12:45:16 GMT
  12. Lines: 52
  13.  
  14.    When the demacs environment variable TZ (time zone) is set in your
  15. emacs.bat file or autoexec.bat file according to Manabu and Hirano's
  16. original instructions as SET TZ=XST-9, where X stands for your own
  17. time zone (CST for me), demacs keeps correct time.  You can
  18. demonstrate this if you type (current-time-string) in a buffer, put
  19. point after it, and then type C-x C-e.  However, for some strange
  20. reason the -9 in the SET TZ statement causes demacs to behave
  21. strangely when you visit a previously created file which is specified
  22. from the command line (for example, "emacs junk.txt").  If you try to
  23. change the file, demacs won't let you do it because of "userlock."  I
  24. have found you can "fix" this by simply asking emacs to revert-buffer;
  25. say "yes" to the prompt (OK, since you just visited the file and no
  26. changes have taken place yet).
  27.  
  28.    The -9 part of the SET TZ statement seems to be at fault since when
  29. you remove it (SET TZ=XST), none of the "userlock" problems occur.
  30. This is described in question 10 of David Steibel's demacs.faq, which
  31. can be obtained from archive.cs.umbc.edu in /pub/demacs.  However,
  32. when you leave the -9 out, demacs's time is all wrong, as you can see
  33. if you try the (current-time-string) trick.  For me, demacs's time is
  34. 14 hours ahead (demacs says 8:00 PM when it's really 6:00 AM);
  35. interestingly, this is the correct time in Japan.  This incorrect time
  36. means that files are labeled with incorrect timestamps and that
  37. calendar programs don't work correctly either.  
  38.  
  39.    I have found that when SET TZ=CST-9 is set and time is correct, I
  40. can avoid the "userlock" problem by simply starting emacs WITHOUT
  41. specifying a file on the command line.  If I then find the file with
  42. C-x C-f, I have no trouble editing the file.  Perhaps someone who
  43. knows what emacs does when it starts up can figure out a way to solve
  44. the "userlock" problem that shows up when you specify the file on the
  45. command line.  I tried using a command line switch ("emacs junk.txt -f
  46. revert-buffer"), but it didn't work.
  47.  
  48.    I think for now I'll just start demacs cleanly from my autoexec.bat
  49. file and use C-x C-f to load all files.
  50.  
  51.    I hope this is helpful, since the userlock is the only "serious"
  52. problem I have had with demacs.  This is especially true after I found
  53. a more recent version of go32.exe (from djdev108.zip or 109; renamed
  54. as demacs.exe) which allowed me to load and edit large (>1MB) text
  55. files.  Thanks to Kevin Gallagher for his tip on this.
  56.  
  57. -----------------------------------------------------------------------
  58. E.J. Neafsey, Ph.D. // Director, Neuroscience Graduate Program         
  59. Department of Cell Biology, Neurobiology & Anatomy                     
  60. Loyola University Medical Center, 2160 S. First Ave., Maywood, IL 60153
  61. Internet: eneafsey@lucpul.it.luc.edu // Bitnet:#m01ejn@luccpua.bitnet  
  62. Phone: +1 708 2163355                                                  
  63. -----------------------------------------------------------------------
  64.  
  65.  
  66.