summaryrefslogtreecommitdiff
path: root/include/git2/config.h
diff options
context:
space:
mode:
authorEtienne Samson <samson.etienne@gmail.com>2018-10-01 21:00:15 +0000
committerEtienne Samson <samson.etienne@gmail.com>2018-10-01 23:14:50 +0200
commit7283daa85863f547c2cf54e48df26b9ffe6f0881 (patch)
tree6dd04be98066632a331e857787e88dab5ac21d79 /include/git2/config.h
parentb3e6ef92637303749359b7302de3f90e16083349 (diff)
downloadlibgit2-7283daa85863f547c2cf54e48df26b9ffe6f0881.tar.gz
doc: small fixups & additions
Diffstat (limited to 'include/git2/config.h')
-rw-r--r--include/git2/config.h20
1 files changed, 15 insertions, 5 deletions
diff --git a/include/git2/config.h b/include/git2/config.h
index 7bcca7da2..b9649f91c 100644
--- a/include/git2/config.h
+++ b/include/git2/config.h
@@ -75,7 +75,17 @@ typedef struct git_config_entry {
*/
GIT_EXTERN(void) git_config_entry_free(git_config_entry *);
-typedef int (*git_config_foreach_cb)(const git_config_entry *, void *);
+/**
+ * A config enumeration callback
+ *
+ * @param entry the entry currently being enumerated
+ * @param payload a user-specified pointer
+ */
+typedef int (*git_config_foreach_cb)(const git_config_entry *entry, void *payload);
+
+/**
+ * An opaque structure for a configuration iterator
+ */
typedef struct git_config_iterator git_config_iterator;
/**
@@ -581,7 +591,7 @@ GIT_EXTERN(int) git_config_iterator_glob_new(git_config_iterator **out, const gi
/**
* Perform an operation on each config variable matching a regular expression.
*
- * This behaviors like `git_config_foreach` with an additional filter of a
+ * This behaves like `git_config_foreach` with an additional filter of a
* regular expression that filters which config keys are passed to the
* callback.
*
@@ -711,11 +721,11 @@ GIT_EXTERN(int) git_config_parse_int64(int64_t *out, const char *value);
GIT_EXTERN(int) git_config_parse_path(git_buf *out, const char *value);
/**
- * Perform an operation on each config variable in given config backend
+ * Perform an operation on each config variable in a given config backend,
* matching a regular expression.
*
- * This behaviors like `git_config_foreach_match` except instead of all config
- * entries it just enumerates through the given backend entry.
+ * This behaves like `git_config_foreach_match` except that only config
+ * entries from the given backend entry are enumerated.
*
* The regular expression is applied case-sensitively on the normalized form of
* the variable name: the section and variable parts are lower-cased. The