How to load latest opened files? Or load specific files?
  Home FAQ Contact Sign in
gnu.emacs.help only
 
Advanced search
POPULAR GROUPS

more...

gnu.emacs.help Profile…
 Up
How to load latest opened files? Or load specific files?         


Author: ssecorp
Date: Sep 1, 2008 16:18

Can I somehow make a command like "open the files that were open last
time emacs was used"?

And can I set a command to open for example:
haskell-mode
c:/mypath/haskell/someprogram.hs

?
4 Comments
Re: How to load latest opened files? Or load specific files?         


Author: B. T. Raven
Date: Sep 1, 2008 20:41

ssecorp wrote:
> Can I somehow make a command like "open the files that were open last
> time emacs was used"?
>
> And can I set a command to open for example:
> haskell-mode
> c:/mypath/haskell/someprogram.hs
>
> ?

Look at Menu Options > Customize Emacs > Specific Option
recentf- tab

The settings I made inserted

'(recentf-max-menu-items 20)
'(recentf-max-saved-items 40)
'(recentf-mode t nil (recentf))

into (Custom-set-variables ...

in my .emacs
There are many recentf options I haven't tried. The defaults seemed
appropriate.
Show full article (0.64Kb)
no comments
Re: How to load latest opened files? Or load specific files?         


Author: Bernardo Bacic
Date: Sep 2, 2008 04:22

it was a dark and stormy night when ssecorp said,
> Can I somehow make a command like "open the files that were open last
> time emacs was used"?
see Saving Emacs Sessions in the manual:
M-: (info "(emacs)Saving Emacs Sessions")
>
> And can I set a command to open for example:
> haskell-mode
> c:/mypath/haskell/someprogram.hs
>
if i understand the question correctly this should be handled by major modes
M-: (info "(emacs)Major Modes")
no comments
Re: How to load latest opened files? Or load specific files?         


Author: Oleksandr Gavenko
Date: Sep 11, 2008 11:30

ssecorp wrote:
> Can I somehow make a command like "open the files that were open last
> time emacs was used"?
>
> And can I set a command to open for example:
> haskell-mode
> c:/mypath/haskell/someprogram.hs
>
> ?
In my .emacs I put

;; ----------------------------------------------
;; *Recentf*
;; Recent files in menu
(require 'recentf)
(recentf-mode t)
(setq recentf-max-saved-items 200)
(global-set-key (kbd "\e\eq") 'recentf-open-files)

If I need file with wich I recently worked I type q and
search by C-s for a needed file.
Show full article (0.64Kb)
no comments
Re: How to load latest opened files? Or load specific files?         


Author: Charles Sebold
Date: Sep 11, 2008 11:45

On 1 Sep 2008, ssecorp wrote:
> Can I somehow make a command like "open the files that were open last
> time emacs was used"?
>
> And can I set a command to open for example:
> haskell-mode
> c:/mypath/haskell/someprogram.hs

Also check out the Desktop functionality:

(info "(emacs)Saving Emacs Sessions")

Or:

C-h r m saving e RET
--
Charles Sebold 11th of September, 2008
no comments