]> code.delx.au - gnu-emacs-elpa/blob - packages/multishell/getting-to-a-shell.md
multishell - merge 1.0.8.
[gnu-emacs-elpa] / packages / multishell / getting-to-a-shell.md
1 Multishell enables you to get to the input prompt in the shell you want
2 with as few keystrokes as possible.
3
4 * One keybinding, unmodified, gets you to the your current default shell, if
5 not in a shell, or to the input prompt of the current shell, if you're in
6 one.
7
8 * Use the universal argument to select a specific shell buffer, wherever
9 point happens to be residing. Enter an empty line to the prompt to go to
10 your current default shell, or use completing read to go to a shell from
11 your multishell history, or start a new shell at the path you specify -
12 including remote paths, using tramp syntax. (See the
13 multishell-pop-to-shell docstring in [multishell.el](multishell.el) for
14 details.)
15
16 * Use a doubled universal argument to set the shell you choose to be the
17 current default. (The prompt will indicate that mode with a "<==".)
18
19 Here's the decision tree:
20
21 * No universal argument - use:
22
23 * From-buffer is shell buffer: use from-buffer current name/path
24 - if shell/connection is stopped, restart/reconnect
25 - if not at input prompt, go there
26 * From-buffer is not shell buffer:
27 - Go to multishell-primary-name current name/path, creating or
28 restarting and/or reconnecting if that shell is not currently running.
29
30 * Universal argument provided - use:
31
32 - No name is specified - use current multishell-primary-name path
33 * Name is specified - use named buffer (creating if not already present):
34 * Path is also specified:
35 - shell is running - ignore new path
36 - shell will be started or restarted - use new path
37 * No path is specified:
38 - Name has history: use path from history
39 - Name has no history: use path that target buffer already has or inherits
40 - If the universal argument is doubled, set the selected shell as the
41 default one, going forwards.