I notice that there are a few global state (or configuration rather) left after this: packed_git_window_size, packed_git_limit and delta_base_cache_limit. These can be changed by $GIT_DIR/config, but since it's still global, a submodule repository will use the same settings of its super repository. If $SUBMODULE/config changes any of these, they are ignored. The natural thing to do is move these to raw_object_store too (and repo_submodule_init needs to check submodule's config file). But one may argue these should be per-process instead of per-repo though. I don't know. But I thought I should mention this. -- Duy