From eee35ad1eeeb89313e69086ad265ab400a6b4898 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Orhun=20Parmaks=C4=B1z?= Date: Fri, 13 Jan 2023 17:25:39 +0300 Subject: [PATCH] fix(changelog): do not skip all tags when `skip_tags` is empty (#136) This is a regression in 8b17a1f02619027bebc5df1a8938aaf76adcd631 --- git-cliff/src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/git-cliff/src/lib.rs b/git-cliff/src/lib.rs index 3bf96c63..32a033fc 100644 --- a/git-cliff/src/lib.rs +++ b/git-cliff/src/lib.rs @@ -60,11 +60,10 @@ fn check_new_version() { /// repository individually. fn process_repository<'a>( repository: &'static Repository, - mut config: Config, + config: Config, args: &Opt, ) -> Result>> { let mut tags = repository.tags(&config.git.tag_pattern, args.topo_order)?; - config.git.skip_tags = config.git.skip_tags.filter(|r| !r.as_str().is_empty()); let skip_regex = config.git.skip_tags.as_ref(); let ignore_regex = config.git.ignore_tags.as_ref(); tags = tags @@ -317,6 +316,7 @@ pub fn run(mut args: Opt) -> Result<()> { args.topo_order = topo_order; } } + config.git.skip_tags = config.git.skip_tags.filter(|r| !r.as_str().is_empty()); // Process the repository. let repositories = args.repository.clone().unwrap_or(vec![env::current_dir()?]);