builtin/clone: create the refdb with the correct object format