diff options
| author | Edward Thomson <ethomson@edwardthomson.com> | 2022-04-11 21:31:25 -0400 |
|---|---|---|
| committer | Edward Thomson <ethomson@edwardthomson.com> | 2022-04-11 22:17:52 -0400 |
| commit | 4161ebdd50dc29205dcc94cba5320c6d0d2537a7 (patch) | |
| tree | e392dbbef54ade88914f7bf1550d2cf8340704a6 /include | |
| parent | fa366921d9d95842660e0dbd9088c83ee0a19873 (diff) | |
| download | libgit2-4161ebdd50dc29205dcc94cba5320c6d0d2537a7.tar.gz | |
repo: make ownership checks optional
Introduce the `GIT_OPT_SET_OWNER_VALIDATION` option, so that users can
disable repository ownership validation.
Diffstat (limited to 'include')
| -rw-r--r-- | include/git2/common.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/include/git2/common.h b/include/git2/common.h index 52000e8eb..c3e3e7b4e 100644 --- a/include/git2/common.h +++ b/include/git2/common.h @@ -225,7 +225,9 @@ typedef enum { GIT_OPT_SET_ODB_PACKED_PRIORITY, GIT_OPT_SET_ODB_LOOSE_PRIORITY, GIT_OPT_GET_EXTENSIONS, - GIT_OPT_SET_EXTENSIONS + GIT_OPT_SET_EXTENSIONS, + GIT_OPT_GET_OWNER_VALIDATION, + GIT_OPT_SET_OWNER_VALIDATION } git_libgit2_opt_t; /** @@ -463,6 +465,14 @@ typedef enum { * > to support repositories with the `noop` extension but does want * > to support repositories with the `newext` extension. * + * opts(GIT_OPT_GET_OWNER_VALIDATION, int *enabled) + * > Gets the owner validation setting for repository + * > directories. + * + * opts(GIT_OPT_SET_OWNER_VALIDATION, int enabled) + * > Set that repository directories should be owned by the current + * > user. The default is to validate ownership. + * * @param option Option key * @param ... value to set the option * @return 0 on success, <0 on failure |
