From 7133af577e1dfce3040f52d0af5d6528d7e3da5e Mon Sep 17 00:00:00 2001 From: Nassim 'Nass' Eddequiouaq Date: Sat, 11 Mar 2017 12:34:22 +0100 Subject: [PATCH] Creds label can be configured from helpers Signed-off-by: Nassim 'Nass' Eddequiouaq --- credentials/credentials.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/credentials/credentials.go b/credentials/credentials.go index ec1aff8..cfe0cb1 100644 --- a/credentials/credentials.go +++ b/credentials/credentials.go @@ -19,8 +19,12 @@ type Credentials struct { // Docker credentials should be labeled as such in credentials stores that allow labelling. // That label allows to filter out non-Docker credentials too at lookup/search in macOS keychain, -// Windows credentials manager and Linux libsecret. -const CredsLabel = "Docker Credentials" +// Windows credentials manager and Linux libsecret. Default value is "Docker Credentials" +var CredsLabel = "Docker Credentials" + +func SetCredsLabel(label string) { + CredsLabel = label +} // Serve initializes the credentials helper and parses the action argument. // This function is designed to be called from a command line interface.