diff options
| author | 2025-10-14 00:23:10 -0400 | |
|---|---|---|
| committer | 2025-10-14 00:23:10 -0400 | |
| commit | 33f8a8a37a9cba738ef25fb99955f0730da9eb48 (patch) | |
| tree | b51fb48b160f5e5e034e6b4542e6f00703bae7ec /gallery_dl/postprocessor | |
| parent | bbe7fac03d881662a458e7fbf870c9d71f5257f4 (diff) | |
New upstream version 1.30.10.upstream/1.30.10
Diffstat (limited to 'gallery_dl/postprocessor')
| -rw-r--r-- | gallery_dl/postprocessor/exec.py | 6 | ||||
| -rw-r--r-- | gallery_dl/postprocessor/ugoira.py | 4 |
2 files changed, 7 insertions, 3 deletions
diff --git a/gallery_dl/postprocessor/exec.py b/gallery_dl/postprocessor/exec.py index ef11bff..3b0ab22 100644 --- a/gallery_dl/postprocessor/exec.py +++ b/gallery_dl/postprocessor/exec.py @@ -55,7 +55,8 @@ class ExecPP(PostProcessor): def _prepare_cmd(self, cmd): if isinstance(cmd, str): - self._sub = util.re(r"\{(_directory|_filename|_path|)\}").sub + self._sub = util.re( + r"\{(_directory|_filename|_(?:temp)?path|)\}").sub return self.exec_string, cmd else: return self.exec_list, [formatter.parse(arg) for arg in cmd] @@ -69,6 +70,7 @@ class ExecPP(PostProcessor): kwdict["_directory"] = pathfmt.realdirectory kwdict["_filename"] = pathfmt.filename + kwdict["_temppath"] = pathfmt.temppath kwdict["_path"] = pathfmt.realpath args = [arg.format_map(kwdict) for arg in self.args] @@ -131,6 +133,8 @@ class ExecPP(PostProcessor): return quote(self.pathfmt.realdirectory) if name == "_filename": return quote(self.pathfmt.filename) + if name == "_temppath": + return quote(self.pathfmt.temppath) return quote(self.pathfmt.realpath) diff --git a/gallery_dl/postprocessor/ugoira.py b/gallery_dl/postprocessor/ugoira.py index 33ebb75..1a55e22 100644 --- a/gallery_dl/postprocessor/ugoira.py +++ b/gallery_dl/postprocessor/ugoira.py @@ -386,7 +386,7 @@ class UgoiraPP(PostProcessor): content.append("") ffconcat = tempdir + "/ffconcat.txt" - with open(ffconcat, "w") as fp: + with open(ffconcat, "w", encoding="utf-8") as fp: fp.write("\n".join(content)) return ffconcat @@ -401,7 +401,7 @@ class UgoiraPP(PostProcessor): content.append("") timecodes = tempdir + "/timecodes.tc" - with open(timecodes, "w") as fp: + with open(timecodes, "w", encoding="utf-8") as fp: fp.write("\n".join(content)) return timecodes |
