Under normal usage, this is called for you when the repository is opened / created, but you can use this to explicitly construct a filesystem refdb backend for a repository.
procedure
( git_refdb_compressrefdb)→integer?
refdb:refdb?
procedure
( git_refdb_freerefdb)→void?
refdb:refdb?
Before the Ref DB can be used for read/writing, a custom database backend must be manually set using git_refdb_set_backend()
git_refdb_dir: read and write loose and packed refs from disk, assuming the repository dir as the folder
procedure
( git_refdb_set_backendrefdbbackend)→integer?
refdb:refdb?backend:refdb_backend?
The git_refdb will take ownership of the git_refdb_backend so you should NOT free it after calling this function.