Signed-off-by: kjuulh <contact@kjuulh.io>
This commit is contained in:
@@ -120,7 +120,8 @@ impl Command {
|
||||
current_dir: Option<&Path>,
|
||||
) -> anyhow::Result<(PleaseConfig, VcsClient, DynRemoteGitClient)> {
|
||||
let config = self.build_config(current_dir)?;
|
||||
let git_client = self.get_git(&config)?;
|
||||
let git_client =
|
||||
self.get_git(&config, self.global.token.clone().expect("token to be set"))?;
|
||||
let gitea_client = self.get_gitea_client(&config);
|
||||
|
||||
let filter = match self.global.log_level {
|
||||
@@ -160,7 +161,7 @@ impl Command {
|
||||
Ok(config)
|
||||
}
|
||||
|
||||
fn get_git(&self, config: &PleaseConfig) -> anyhow::Result<VcsClient> {
|
||||
fn get_git(&self, config: &PleaseConfig, token: String) -> anyhow::Result<VcsClient> {
|
||||
if self.global.no_vcs {
|
||||
Ok(VcsClient::new_noop())
|
||||
} else {
|
||||
@@ -168,6 +169,7 @@ impl Command {
|
||||
config.get_source(),
|
||||
config.settings.git_username.clone(),
|
||||
config.settings.git_email.clone(),
|
||||
token,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user