On Thursday, August 28, 2014 6:41 AM, Andy Bradford wrote:
Thus said Andy Gibbs on Wed, 27 Aug 2014 18:58:21 +0200:
Is there a rationale behind this? Could there be a flag (e.g. -q /
--quiet would work!) that can do an automatic "yes" at this point?
I'm not sure about the rationale except perhaps it could be ambiguous.
There are potentially other prompts that could be issued during cloning.
So simply echoing "y" into the fossil clone command could be ambiguous.
Yes, this is the worst-case high-maintenance option, but surprisingly
common!
Would the -q / --quiet apply an implied "y" to the username/password
prompt only or would others be impacted?
Ordinarily a "quiet" option would take the default value for any prompts.
The prompts have default values already (in this case, simply hitting return
means yes). This would actually be quite a neat solution since it seems
fossil factors out prompts into their own functions, so on entering the
function it can determine whether the -q option has been given and return
the default value for that prompt. I would assume, that would mean a blank
password where the password is prompted, for example.
I would advocate the "quiet" option being global for all fossil commands.
Maybe a --keep-password option would be less ambiguous?
Alternatively, if you're scripting the clone with a username/password,
have you considered scripting the syncs with the same username/password?
I did, but there are a number of different scripts. From a script
durability point of view, it would be good, since fossil *can* remember
passwords, for it to do so during clone.
Cheers,
Andy (another one)
Andy
--
TAI64 timestamp: 4000000053feb33a
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users