lynx-dev
[Top][All Lists]
Advanced

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

Re: LYNX-DEV Using $HOME/.lynx to store lynx config files


From: Andrew Kuchling
Subject: Re: LYNX-DEV Using $HOME/.lynx to store lynx config files
Date: Mon, 16 Jun 1997 18:47:07 -0400 (EDT)

Alex Lyons wrote:
> I suggest that the second choice (/tmp/.lynx) ought to first require
> confirmation, and that the third choice, just putting the files in Home_Dir,
> should be replaced by a question like "in what directory would you like to
> put your Lynx configuration files?"

        There's a problem here, though; Lynx_Dir() is called before
start_curses(), so the code can't uses curses functions to produce
output in the status bar.  Should it use fgets() on stdin in
interactive mode?  I don't think Lynx can ask "what directory would
you like?" since how will it remember that directory for next time?
It can't be put in lynx.cfg, since it may be system-wide and not
modifiable; it can't put it in .lynxrc since .lynxrc is in that
directory!  (Perhaps .lynxrc should just stay where it is?)

> Other files that could go in there, in addition to cookies and certs, would be
> bookmarks, Lynx.trace, user-modified jumpfile, mime.types and mailcap, and a
> persistent access/proxy authentication database (if I or anyone else ever get
> round to writing the code to let lynx dump/load its data structures).

        I disagree; only things that Lynx can generate or modify on
its own should go in Lynx_Dir().  .mailcap and mime.types may be used
by other software, so they can't really be moved.  The jumpfile can't
be modified from inside Lynx, and the whole point of Lynx.trace is
looking at it, so IMHO they shouldn't go in a hidden directory making
the user chase them down.  Bookmarks I'm not sure about, but am
leaning toward putting them in Lynx_Dir(); people do edit them
manually, but Lynx does allow adding and removing entries.

Emil Sit wrote:
>So the question then is how to deal best with having multiple names
>for files --- one name for inside and one name for outside. One
>solution would be to write a "convert" script to move all appropriate

        Perhaps a more general path searching function should be
written and used for files (assuming there isn't already such a
function hiding somewhere).  For example, then the ~/.lynx, ~, and
/usr/local/lib directories could be checked in turn.  That has a nice
side effect; you could take the system-wide lynx.cfg, modify it, and
put it in your home directory or ~/.lynx, and it would automatically
override the system-wide version.

>files from the outside to the inside. Another would be to have a
>function which returned the appropriate name --- prepending a
>"~/.lynx" or "~/.lynx/" to the base filename as necessary.

        There's a LYAddPathToHome(), which could have a corresponding
LYAddPathToLynxDir() function; I didn't make one because it wasn't
needed for .lynxrc, but it's not hard.  Does it seem useful?
(Remember, there's no provision for making subdirectories of .lynx, so
it's not like you can write to ~/.lynx/cache/doc12.)


        Andrew Kuchling
        address@hidden
        http://people.magnet.com/%7Eamk/

;
; To UNSUBSCRIBE:  Send a mail message to address@hidden
;                  with "unsubscribe lynx-dev" (without the
;                  quotation marks) on a line by itself.
;

reply via email to

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