The '--interactive' switch is only for the sqlite shell I think. It is
not accepted for the remote-url command.
Simple test case:
$ fossil remote-url https://a:[email protected]/
remember password (Y/n)? y
https://[email protected]/
$ yes | fossil remote-url https://a:[email protected]/
https://[email protected]/
The problem is that `save_password_prompt` never gets called if the
stdin is not a tty. There are two code paths leading to it, and both are
guarded by `isatty(fileno(stdin))`:
https://fossil-scm.org/index.html/artifact?udc=1&name=61b100991bd4e137&ln=279-280
https://fossil-scm.org/index.html/artifact?udc=1&name=61b100991bd4e137&ln=552+561
I think one fix is to factor out the `isatty(fileno(stdin))` in a
separate function, which checks the environment for a
`FOSSIL_FORCE_INTERACTIVE` variable (or a new global command-line switch).
That, and/or add a `--remember-password` option to `remote-url`.
On 06/08/2018 10:24 AM, Warren Young wrote:
On Jun 8, 2018, at 2:47 AM, Eduard <[email protected]> wrote:
Maybe it would be possible to add a command-line switch to force it to remember
the password, or a switch to make it pretend stdin is a tty?
It looks like that last is already available: -interactive.
I’m not aware of any place that all of the global options to Fossil are
documented. I had to dig through the command line parser in main() within
src/shell.c to find it.
I’m not certain that this option will affect your symptom. If not, let us know
exactly what method you’re trying and what symptom you get when it fails, if it
does.
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users