LINUX.ORG.RU
Ответ на: комментарий от anonymous

А конкретный рецептик можно (для таких тупых и ленивых как я:-))? А то при редактировании текста программы есть необходимость держать открытыми еще как минимум два файла (C-x 3 и C-x 2 в купе с C-x C-f делают свое дело), хотелось бы обезьянью работы по их открытию при старте emacs-а свести к минимуму.

Alexey-ZAR
()
Ответ на: комментарий от Alexey-ZAR

You can use the Desktop library to save the state of Emacs from one session to another. Saving the state means that Emacs starts up with the same set of buffers, major modes, buffer positions, and so on that the previous Emacs session had.

To use Desktop, you should use the Customization buffer (see section Easy Customization Interface) to set desktop-enable to a non-nil value, or add these lines at the end of your `.emacs' file:

(desktop-load-default) (desktop-read)

http://www.phys.ufl.edu/docs/emacs/emacs_423.html#SEC430

anonymous
()
Ответ на: комментарий от anonymous

Спасибо! Почти работает: команды desktop-load-default у меня почему-то нет, desktop-read открывает все необходимые файлы, вот только разбивку окна emacs-а на несколько не сохраняет. Это как-нибудь правится? Или как всегда, "нет в жизни счастья"?:)

Alexey-ZAR
()
Ответ на: комментарий от Alexey-ZAR

Небольшая правка: может, команда и есть (во всяком случае, emacs при запуске не ругается), но по M-x она не показывается.

Alexey-ZAR
()
Ответ на: комментарий от Alexey-ZAR

The first time you save the state of the Emacs session, you must do it manually, with the command M-x desktop-save. Once you have done that, exiting Emacs will save the state again--not only the present Emacs session, but also subsequent sessions. You can also save the state at any time, without exiting Emacs, by typing M-x desktop-save again.

anonymous
()
Ответ на: комментарий от anonymous

Именно так и делал, файлы в буферы грузит, а вот окошки не открывает (т.е. C-X 3 & C-X 2 все еще приходится нажимать, а вместо C-X F теперь жму C-X B для переключения буферов).

Alexey-ZAR
()
Вы не можете добавлять комментарии в эту тему. Тема перемещена в архив.