From: Peter Graves <peter@ar...> - 2002-07-28 19:28:56
This morning's 0.16.0+ development snapshot is up:
http://armedbear.org/j.zip (source and documentation)
http://armedbear.org/j-jar.zip (just j.jar)
By request, this snapshot adds basic support for named sessions.
J has always saved information about your editing session, so that by
default, when you restart j, things come back more or less as you left
them: the same buffers will be open (except for remote, transient and
weird buffers), and the current location in each buffer will be the
The commands saveSession and loadSession, new in this snapshot, add
support for named sessions.
saveSession saves information about the current editing session in a
named session file. If no named session is active yet, you will be
prompted for a name for the current session; subsequent saves will go
to that session file without further prompting. =
loadSession loads a named session that you have previously saved,
which then becomes the active named session as far as saveSession is
concerned. All currently open buffers are closed before the new
session is loaded.
The "Name:" textfield, in the dialog that comes up when you do
loadSession or saveSession, supports both history and completion; if
you hit Tab when the textfield is empty you'll cycle through all the
named session files in your collection.
If a named session is active, you can save the current session under a
new name by using executeCommand to invoke saveSession with the new
name as an argument (e.g. Alt X, "saveSession foo"). If you do this,
subsequent saves will go to the new session file ("foo") by default. =
When a named session is active, the session name appears in the title
bar of the top-level window, enclosed in brackets. =
By default, the information in a named session file is only updated
when you explicitly invoke saveSession. This allows you to exercise
better control over the contents of named session files. If you'd like
named session information to be updated automatically, add this line
to ~/.j/prefs or C:\.j\prefs: =
autosaveNamedSessions =3D true
You can use "-session" on the command line to start j with a specific
named session: =
j -session foo
java -jar j.jar -session foo
When you start j without specifying a named session on the command
line, the previous session is restored, but no named session is active
until you do saveSession or loadSession.
In the current implementation, only the buffer list is saved in the
named session file. This means that command history (among other
things) is global across named sessions. It would be nice to store
command history in the named session files too, but I'd like to make
sure the basic functionality is solid first. The folks who requested
this feature were mainly interested in the buffer list (or so they
Preliminary documentation about named sessions has been added to j's
help system (F1, scroll down to "Sessions" and hit Enter).
Of course, if you don't care about named sessions, you can ignore all
of this and j will behave exactly as it always has.
If you do try out the named sessions feature, please let me know what
you think of it from a usability perspective.
Named sessions (rather than documentation of the tag file functionality =
as originally planned) will probably be the main focus of 0.16.1, which
I hope to release by mid-week.
Thanks for your support.