pan-devel
[Top][All Lists]
Advanced

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

Re: [Pan-devel] When the NSP company tells us the headers will be re-num


From: Duncan
Subject: Re: [Pan-devel] When the NSP company tells us the headers will be re-numbered, what should we make Pan do?
Date: Thu, 18 Dec 2014 21:25:38 +0000 (UTC)
User-agent: Pan/0.140 (Chocolate Salty Balls; GIT 4c6f250 /m/p/portage/src/egit-src/pan2)

SciFi posted on Wed, 17 Dec 2014 20:21:31 +0000 as excerpted:

> I found a file named 'newsrc-1',
> probably because it's the 1st newsrc in case of multiple servers.
> (In this case it's the only one.)

Note that in the case of multiple servers, servers.xml provides the 
server/newsrc mapping.

Here, I've actually changed the names of the files, making the 
corresponding change in servers.xml as well, so they reflect the name of 
the server, not just whatever random order I happened to add them to the 
server list in.  =:^)  Of course, I did that so long ago I couldn't 
remember the default names, but I guess I could have mentioned the 
servers.xml mapping.

> I renamed it then started Pan but then it showed no subscribed groups
> even after I got a fresh grouplist.

Hmm...  Interesting.  I haven't fully investigated how pan tracks 
subscriptions, but as I said, it doesn't seem to be entirely by the :/! 
in the newsrc files, as many of my subscribed groups still show !.

But I did say back it up just in case, and now I'm glad I did. =:^)

> I then quickly Shut Pan down.
> Decided to edit that file and rub-out all the numbers it'd been saving.
> 
> Then saved the file back to 'newsrc-1'
> and started Pan again.
> 
> The subscribed grouplist came back.
> And I think the GUI can now count/show the new msgs properly and the
> hilighting for unread-vs-read is proper, too.
> I think.  ;)

=:^)

> Here's how I edited those numbers to wipe 'em out:
> 
> I've been using TextWrangler editor for Macs (freely available here,
>  <http://www.barebones.com/products/textwrangler/>).
> It can do changes based on its interpretation of Grep,
> so I came up with Find/Replace strings to clean-out the newsrc numbering
> scheme:
> 
>     Find:  \:\ [0-9].*\n
>  Replace:  \:\n
> 
> then change the beginning '\:' to '\!' on both to clean-out the other
> lines with those numbers.
> 
> I bet this can be done easily with CLI cmds but I like the way
> TextWrangler can back ya up in case something gets really messy.  ;)

FWIW, I'd have probably done something very similar here, using mcedit (mc 
being midnight commander, the commander-like ncurses-based semi-gui file 
manager, with mcedit of course being its native editor).  mcedit has 
gradually become my favorite text editor over the years as it works the 
same at a text login without X running as it does in an x-based terminal 
window, as it does over ssh, with a relatively intuitive yet extensible 
interface.  Correspondingly, mc is my favorite "sysadmin hat" file 
manager, tho when I'm doing "user hat" stuff like managing media files 
(umm, pretty much exclusively that...), a full GUI file manager tends to 
work better.

> Now, I ask if we can get Mr H.M. to consider a built-in feature to wipe
> these numbers off of 'newsrc' in these special cases?  I'll try writing
> a "feature request" bugreport if ok.
> Else, at least we-all have a documented method to do this here.

Now that I think about it (I forgot this in the earlier reply, or I'd 
have mentioned it), I believe the GUI way to do it is the following:

Create a new server with the same server properties as the old one.  
Because pan is server-transparent, the same subscribed groups apply, and 
after downloading the new group list, deleting the old one (or setting it 
to 0 connections and keeping it until all its messages have expired, if 
you want to keep them) should do just what you needed. =:^)

That should work nicely, because in that case effectively all that has 
changed is the newsrc file, since the server properties were duplicated.

But I know you to be technical enough that direct-editing the newsrc file 
wasn't a big deal, and in fact might actually be preferred, since you now 
know more about pan's working than you did before. =:^)

But a button on the individual server settings dialog to reset groups 
would indeed be more intuitive.  I'd simply suggest an "are you sure?" 
dialog, with an explanation that it would reset downloaded and read 
message tracking, for those who might otherwise hit it accidentally or 
out of curiosity and then wonder why pan's suddenly showing messages as 
unread, once again.

-- 
Duncan - List replies preferred.   No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master."  Richard Stallman




reply via email to

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