11

lynx -cfg=cfg.file $URL

this works with the following contents of the .cfg file:

SET_COOKIES:TRUE
ACCEPT_ALL_COOKIES:TRUE
PERSISTENT_COOKIES:TRUE
COOKIE_FILE:cookie.file

however, this does not:

lynx -cookies=1 -accept_all_cookies=1 -cookie_file=cookie.file $URL

if it's going to be of any help - here's the trace:

parse_arg(arg_name=-cookies=1, mask=1, count=2)
parse_arg lookup(cookies=1)
...skip (mask 1/4)
parse_arg(arg_name=-accept_all_cookies=1, mask=1, count=3)
parse_arg lookup(accept_all_cookies=1)
...skip (mask 1/4)
parse_arg(arg_name=-cookie_file=cookie.file, mask=1, count=4)
parse_arg lookup(cookie_file=cookie.file)
...skip (mask 1/4)
parse_arg(arg_name=$URL, mask=1, count=5)
parse_arg startfile:$URL

obvious question, why? the actual difference, from what i see, is the inability to trigger "PERSISTENT_COOKIES:TRUE" by command-line options in lynx. or, maybe, i have overlooked/misunderstood something?

XXL
  • 1,489

2 Answers2

3

The following document implies that you can get this behavior by compiling Lynx with the --enable-persistent-cookies flag. The behavior is disabled by default, but implied to be enabled with this configuration flag.

You can use checkinstall or similar to easily create a package for your system from source.

Source: http://lynx.isc.org/release/lynx2-8-7/lynx_help/Lynx_users_guide.html#Cookies

bertieb
  • 7,543
1

Try setting -cookie_save_file to the same file.

mgorven
  • 2,887