MCPcopy Create free account
hub / github.com/libgit2/pygit2 / Repository_workdir__set__

Function Repository_workdir__set__

src/repository.c:500–514  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

498}
499
500int
501Repository_workdir__set__(Repository *self, PyObject *py_workdir)
502{
503 const char *workdir = pgit_borrow(py_workdir);
504 if (workdir == NULL)
505 return -1;
506
507 int err = git_repository_set_workdir(self->repo, workdir, 0 /* update_gitlink */);
508 if (err) {
509 Error_set_str(err, workdir);
510 return -1;
511 }
512
513 return 0;
514}
515
516PyDoc_STRVAR(Repository_descendant_of__doc__,
517 "descendant_of(oid1: Oid, oid2: Oid) -> bool\n"

Callers

nothing calls this directly

Calls 2

pgit_borrowFunction · 0.85
Error_set_strFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…