Changes the way files names are done.
Some readers like this one better.
This commit is contained in:
@@ -467,19 +467,19 @@ class ComicStrip(ImageRepo, ABC):
|
||||
|
||||
:returns: A human-friendly file, like "05 - Riddles in the Dark" or "2025-06-01 - Chapter 5."
|
||||
"""
|
||||
prefix_num_form = "{:02}"
|
||||
prefix_num_form = "#{:02}"
|
||||
if type(self.identifier) == int:
|
||||
prefix = prefix_num_form.format(self.identifier)
|
||||
elif (type(self.identifier) == list or type(self.identifier) == tuple) and type(self.identifier[-1]) == int:
|
||||
prefix = prefix_num_form.format(self.identifier[-1])
|
||||
elif type(self.date) == date:
|
||||
prefix = self.date.isoformat()
|
||||
prefix = self.date.strftime("#%Y%m%d")
|
||||
elif type(self.date) == datetime:
|
||||
prefix = self.date.date().isoformat()
|
||||
prefix = self.date.date().strftime("#%Y%m%d")
|
||||
else:
|
||||
prefix = self.get_identifier_string()
|
||||
if self.title:
|
||||
return (prefix + " - " + file_safe_string(self.title))[0:250]
|
||||
return (file_safe_string(self.comic.title) + " " + prefix + " - " + file_safe_string(self.title))[0:250]
|
||||
else:
|
||||
return prefix
|
||||
|
||||
|
||||
Reference in New Issue
Block a user