mirror of
https://github.com/drewcassidy/yaclog-ksp.git
synced 2024-09-01 14:58:44 +00:00
Addresses #2
This commit is contained in:
parent
6bc2ec1940
commit
939b39c3e6
@ -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)])
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user