From 939b39c3e6374c890a554a167ddee68b3c73eae8 Mon Sep 17 00:00:00 2001 From: Andrew Cassidy Date: Sun, 25 Aug 2024 23:03:03 -0700 Subject: [PATCH] Addresses #2 --- yaclog_ksp/__main__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yaclog_ksp/__main__.py b/yaclog_ksp/__main__.py index 93d27e9..8d4f89b 100644 --- a/yaclog_ksp/__main__.py +++ b/yaclog_ksp/__main__.py @@ -39,7 +39,7 @@ def main(path, outpath, name): pathname = pathlib.Path.cwd().name.removeprefix('KSP-') modslug = str.join('', [s.title() for s in re.split(r'[ _-]+', pathname)]) segments = re.findall(r'[A-Z](?:[a-z]+|[A-Z]*(?=[A-Z]|$))', modslug) - name = segments[0] + [' ' + s for s in segments[1:]] + name = ' '.join(segments) else: modslug = str.join('', [s.title() for s in re.split(r'[ _-]+', name)])