Go to the first, previous, next, last section, table of contents.

# Session Groups

Several major entries of Ediff perform comparison and merging on directories. On entering `ediff-directories`, `ediff-directories3`, `ediff-merge-directories`, `ediff-merge-directories-with-ancestor`, `ediff-directory-revisions`, `ediff-merge-directory-revisions`, or `ediff-merge-directory-revisions-with-ancestor`, the user is presented with a Dired-like buffer that lists files common to the directories involved along with their sizes. (The list of common files can be further filtered through a regular expression, which the user is prompted for.) We call this buffer Session Group Panel because all Ediff sessions associated with the listed files will have this buffer as a common focal point.

Clicking button 2 or typing `RET` or `v` over a record describing files invokes Ediff in the appropriate mode on these files. You can come back to the session group buffer associated with a particular invocation of Ediff by typing `M` in Ediff control buffer of that invocation.

Many commands are available in the session group buffer; some are applicable only for certain types of work. The relevant commands are always listed at the top of each session group buffer, so there is no need to memorize them.

In directory comparison or merging, a session group panel displays only the files common to all directories involved. The differences are kept in a separate buffer and are conveniently displayed by typing `D` to the corresponding session group panel. Thus, as an added benefit, Ediff can be used to compare the contents of up to three directories.

Session records in session group panels are also marked with `+`, for active sessions, and with `-`, for finished sessions.

Sometimes, it is convenient to exclude certain session records from a group. Usually this happens when the user doesn't intend to run Ediff of certain files in the group, and the corresponding session records just add clutter to the session group buffer. To help alleviate this problem, the user can type `h` to mark a session as a candidate for exclusion and `x` to actually hide the marked sessions. There actions are reversible: with a prefix argument, `h` unmarks the session under the cursor, and `x` brings the hidden sessions into the view (`x` doesn't unmark them, though, so the user has to explicitly unmark the sessions of interest).

Group sessions also understand the command `m`, which marks sessions for future operations (other than hiding) on a group of sessions. At present, the only such group-level operation is the creation of a multi-file patch.

A multi-file patch is a concatenated output of several runs of the Unix ``diff'` command (some versions of ``diff'` let you create a multi-file patch in just one run). In a session group buffer created in response to `ediff-directories` or `ediff-directory-revisions`, the user can type `P` to create a multi-file patch of marked sessions (which must be marked using the `m` command). Ediff then will display a buffer containing the patch. In an `ediff-directories` session, it is enough to just mark the requisite sessions. In `ediff-directory-revisions` revisions, the marked sessions must also be active, or else Ediff will refuse to produce a multi-file patch. This is because, in the latter-style sessions, there are many ways to create diff output, and it is easier to handle by running Ediff on the inactive sessions.

Go to the first, previous, next, last section, table of contents.