问题描述
我想绕过Press return to continue.
一致问题(在同步是初始同步时会发生。如果不是第一次同步,则不会出现此问题,因此expect
应该会出现能够知道这一点而无所事事)。当出现此问题时,应使用expect
键入空格,以使一致继续前进。
但是我仍然希望能够为后继问题做出选择。
有人知道如何通过expect
实现这一目标吗?谢谢。
$ unison -root o1 -root o2
Unison 2.51.2 (ocaml 4.08.1): Contacting server...
Looking for changes
Warning: No archive files were found for these roots,whose canonical names are:
/private/tmp/o1
/private/tmp/o2
This can happen either
because this is the first time you have synchronized these roots,or because you have upgraded Unison to a new version with a different
archive format.
Update detection may take a while on this run if the replicas are
large.
Unison will assume that the 'last synchronized state' of both replicas
was completely empty. This means that any files that are different
will be reported as conflicts,and any files that exist only on one
replica will be judged as new and propagated to the other replica.
If the two replicas are identical,then no changes will be reported.
If you see this message repeatedly,it may be because one of your machines
is getting its address from DHCP,which is causing its host name to change
between synchronizations. See the documentation for the UNISONLOCALHOSTNAME
environment variable for advice on how to correct this.
Donations to the Unison project are gratefully accepted:
http://www.cis.upenn.edu/~bcpierce/unison
Press return to continue.[<spc>] Reconciling changes
o1 o2
file ----> x.txt [f] f
Proceed with propagating updates? [] y
解决方法
见unison -help
Basic options:
-auto automatically accept default (nonconflicting) actions
-batch batch mode: ask no questions at all