[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Unknown option `--no-desktop'
From: |
Robert J. Chassell |
Subject: |
Re: Unknown option `--no-desktop' |
Date: |
Tue, 16 Nov 2004 13:47:14 +0000 (UTC) |
"Stephan Stahl" <address@hidden> said
... i do not understand why you have some lines in you .emacs
files that cause the desktop to get saved. desktop.el should do
that automaticly when emacs is killed. ...
This is so I can avoid using the desktop with specifically named
instances of Emacs. Here is what I say in my .emacs file:
;; Do not use desktop-save-mode for Short or Experimental Emacs:
(if (or
(string= (cdr (assq 'name (frame-parameters))) "Bobs Short Emacs")
(string= (cdr (assq 'name (frame-parameters))) "Experimental Emacs"))
(desktop-save-mode 0)
(desktop-save-mode 1))
Here is my proposal for how the start up option should work:
1. Emacs started with emacs -Q --no-desktop
-- Do not start a desktop, since there is none; do nothing.
-- _Also_,
do not say "Unknown option `--no-desktop'"
but do nothing since the initial option should be recognized
as having nothing to work on.
2. Emacs started with emacs --no-desktop
and with a .emacs file that says (desktop-save-mode 1)
(and no desktop function called during session)
-- Do not start the desktop
-- Do not save a desktop when this instance of Emacs is ended
3. Emacs started with emacs --no-desktop
and with a .emacs file that says (desktop-save-mode 1)
but a desktop function is called during the session
after this instance of Emacs has started
-- Do whatever the desktop function says
4. Emacs started with emacs --no-desktop
and with a .emacs file that says (desktop-read "/user")
-- Do not start the desktop
-- If a desktop function is called during the session,
do whatever it says.
A key question is whether the single option --no-desktop should do two
different actions, in effect, combine two different options:
* --no-desktop-read: prevent starting a desktop when an instance of
Emacs starts,
but permitting a save when the .emacs file says
(desktop-save-mode 1)
* --no-desktop-save: prevent saving a desktop when an instance of
Emacs ends,
but permitting a pre-existing desktop to be read,
and not changing it during the session, when the .emacs file says
(desktop-save-mode 1)
I think there should be just the one option --no-desktop and it should
do both actions. Morover the one option should apply only to the
start up. If you call a desktop function when running, then that
should take effect, just as your .emacs file gets loaded if you load
your .emacs after starting with `emacs -Q'.
Under no circumstances should the message
Unknown option `--no-desktop'
appear, as it does with this morning's CVS, of Tue, 2004 Nov 16 12:52
UTC, GNU Emacs 21.3.50.7 (i686-pc-linux-gnu, GTK+ Version 2.4.13)
started with
emacs -Q --no-desktop
--
Robert J. Chassell
address@hidden GnuPG Key ID: 004B4AC8
http://www.rattlesnake.com http://www.teak.cc