Web lists-archives.com

Re: mandb -p deleting "obsolete" Windows cat directories




On 2018-01-22 22:35, L A Walsh wrote:
> Brian Inglis wrote:
>> Removing obsolete cat directory /proc/cygdrive/c/Windows/en-US...
>> "
>> which is kind of worrisome, especially when the complete path is not shown!
>>   
> Ouch!
> 
> You might try loading the source of the program and searching for 'obsolete'
> in the sources -- (grep -ir obsolete '<dir>').  Comments or notes might give
> some hints..?

Obvious patch is "if (purge) purge_catdirs(...);" which disables it with -p.

Already looked and no obvious reason why whole drive scanned, rather than just
system cat dirs without matching man dirs.

Need to check further if it tests that cat dirs are empty before removal.
I use cat dirs for e.g. Windows help, command /?, program --help output,
anything without man pages, to avoid having to remember how to do that.
I don't want those purged either - I would be mighty POed - some are from
strings searches thru exes and online docs!

>> Question is why does mandb scan the whole drive, think Windows cat
>> directories are its property, delete them while running with -p, and
>> suggestions for how> Also, might check if any of places it scans are symlinks?
Most man symlinks are created by me for specific purposes and valid from my
checks using "find -L ... -type l | xargs ls -dl --color".
PATH profile function checks for accessible real path names to guarantee order,
existence, eliminate duplicates, and reduce search overhead.

Looks like I have to patch as above, rebuild with debuginfo, and run with
debugging output under gdb.
Then I want to complete the details on the mandb page, as any directory starting
with two lowercase letters, optionally followed by any non-lowercase character,
with any subdirectory starting with cat, without a matching subdirectory
starting with man followed by the (possibly null) suffix for cat, gets wiped
e.g. abZ/catalog/ goes unless abZ/manalog/ exists.
Then possibly add another option --no-purge-obsolete patch to switch that off!

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple