Skip to content

Commit

Permalink
Update version and fix file sorting in clip_audio function (#7)
Browse files Browse the repository at this point in the history
* Update version and fix file sorting in clip_audio function

* Fix file sorting in clip_audio function
  • Loading branch information
ReinderVosDeWael authored Dec 19, 2023
1 parent 74ec672 commit 124c33c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "cloai"
version = "0.0.1a7"
version = "0.0.1a8"
description = "A CLI for OpenAI's API"
authors = ["Reinder Vos de Wael <[email protected]>"]
license = "LGPL-2.1"
Expand Down
4 changes: 3 additions & 1 deletion src/cloai/cli/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@ def clip_audio(
logger.warning("Running ffmpeg: %s", " ".join(stream.compile()))
stream.run()

yield from pathlib.Path(out_dir).glob(f"*{uuid_id}*.mp3")
files = list(pathlib.Path(out_dir).glob(f"*{uuid_id}*.mp3"))
files.sort()
yield from files


def download_file(filename: str | pathlib.Path, url: str) -> None:
Expand Down

0 comments on commit 124c33c

Please sign in to comment.