Allow git repo queries without a clone when update=no

This commit also makes the dest parameter optional, unless update=yes
(the default), since it is not required for queries without an update.

Fixes #8630