aboutsummaryrefslogtreecommitdiffstats
path: root/credential.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2025-01-21 08:44:54 -0800
committerJunio C Hamano <gitster@pobox.com>2025-01-21 08:44:54 -0800
commit7b39a128c814a2362d0533c7df0ab7a2fef6fa4b (patch)
tree6f348b269516bb30655e03ef6a637609d007c5d2 /credential.h
parentMerge branch 'jt/fsck-skiplist-parse-fix' (diff)
parentmatch-trees: stop using `the_repository` (diff)
downloadgit-7b39a128c814a2362d0533c7df0ab7a2fef6fa4b.tar.gz
git-7b39a128c814a2362d0533c7df0ab7a2fef6fa4b.zip
Merge branch 'ps/the-repository'
More code paths have a repository passed through the callchain, instead of assuming the primary the_repository object. * ps/the-repository: match-trees: stop using `the_repository` graph: stop using `the_repository` add-interactive: stop using `the_repository` tmp-objdir: stop using `the_repository` resolve-undo: stop using `the_repository` credential: stop using `the_repository` mailinfo: stop using `the_repository` diagnose: stop using `the_repository` server-info: stop using `the_repository` send-pack: stop using `the_repository` serve: stop using `the_repository` trace: stop using `the_repository` pager: stop using `the_repository` progress: stop using `the_repository`
Diffstat (limited to 'credential.h')
-rw-r--r--credential.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/credential.h b/credential.h
index 63fef3e2ea..c78b72d110 100644
--- a/credential.h
+++ b/credential.h
@@ -4,6 +4,8 @@
#include "string-list.h"
#include "strvec.h"
+struct repository;
+
/**
* The credentials API provides an abstracted way of gathering
* authentication credentials from the user.
@@ -65,7 +67,7 @@
* // Fill in the username and password fields by contacting
* // helpers and/or asking the user. The function will die if it
* // fails.
- * credential_fill(&c);
+ * credential_fill(repo, &c);
*
* // Otherwise, we have a username and password. Try to use it.
*
@@ -222,7 +224,8 @@ void credential_clear(struct credential *);
* If all_capabilities is set, this is an internal user that is prepared
* to deal with all known capabilities, and we should advertise that fact.
*/
-void credential_fill(struct credential *, int all_capabilities);
+void credential_fill(struct repository *, struct credential *,
+ int all_capabilities);
/**
* Inform the credential subsystem that the provided credentials
@@ -231,7 +234,7 @@ void credential_fill(struct credential *, int all_capabilities);
* that they may store the result to be used again. Any errors
* from helpers are ignored.
*/
-void credential_approve(struct credential *);
+void credential_approve(struct repository *, struct credential *);
/**
* Inform the credential subsystem that the provided credentials
@@ -243,7 +246,7 @@ void credential_approve(struct credential *);
* for another call to `credential_fill`). Any errors from helpers
* are ignored.
*/
-void credential_reject(struct credential *);
+void credential_reject(struct repository *, struct credential *);
/**
* Enable all of the supported credential flags in this credential.