nano-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Nano-devel] RFC: limiting the amount of position history


From: Benno Schulenberg
Subject: Re: [Nano-devel] RFC: limiting the amount of position history
Date: Tue, 19 Jan 2016 13:27:45 +0100

> > So I propose to limit the number of entries in the positions-
> > history file to 100 or 200, or at the very most 500.
> 
> That sounds great, but you run into two problems.
> 1. What gets deleted? Oldest entry? I might want that entry.

Ah...  Good point.  When nano updates an entry, it should
promote that entry to be the most recent one.  Will implement
that.  Currently it updates an entry in place.

> 2. If you did it statistically, most used file, then nano would become a
>    bit creepy IMHO.

Not statistically, too much work.  Just keep the files that were
recently used at the "head" of the list (actually the tail), so
that only files that haven't been touched for two hundred times
drop off the list.

> I think that you should mention this in nano docs,

Yeah, the limit of 200 should be mentioned.  Will do that.

> even add an option maybe.

No, please, not another option!  :)

> It's a good idea, most editors implement a recently used list of sorts,
> but IMHO, it's hard to get right.

Well, looks pretty easy to me.

> Mine will grow till I use nano to
> shorten it.

That will require the cleverness of starting nano with --ignore.

> A great idea would be to (optionally) compress the file, say lzo, gz,
> etc.

Arh, no!  Far too much trouble!  And it's not about the size,
it's about nano remembering where I was in a file that I edited
more than a year ago.  It shouldn't do that; it should consider
that file as if it had never seen it before and start at the top.
And no, I don't want to add timestamps.  It should be something
simple.  The 200 most-recently-used is something simple.

Benno

-- 
http://www.fastmail.com - Accessible with your email software
                          or over the web




reply via email to

[Prev in Thread] Current Thread [Next in Thread]