From ae36f300baaa16031ea1de6f660a5ee53bc9fdc9 Mon Sep 17 00:00:00 2001 From: Eric Joanis Date: Tue, 4 Feb 2025 14:04:00 -0500 Subject: [PATCH 1/3] build: convert setup.py to pyproject.toml --- fs2/_version.py | 1 + pyproject.toml | 51 ++++++++++++++++++++++++++++++++++++++++++++ requirements.dev.txt | 13 ----------- requirements.txt | 1 - setup.py | 45 -------------------------------------- 5 files changed, 52 insertions(+), 59 deletions(-) create mode 100644 fs2/_version.py create mode 100644 pyproject.toml delete mode 100644 requirements.dev.txt delete mode 100644 requirements.txt delete mode 100644 setup.py diff --git a/fs2/_version.py b/fs2/_version.py new file mode 100644 index 0000000..1cf6267 --- /dev/null +++ b/fs2/_version.py @@ -0,0 +1 @@ +VERSION = "0.1.0" diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..6cb5fc9 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,51 @@ +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +[project] +name = "fs2l" +dynamic = ["version"] +description = "Text-to-Speech Synthesis for the Speech Generation for Indigenous Language Education Small Teams Project" +license = "MIT" +readme = "readme.md" +requires-python = ">=3.10" +authors = [ + { name = "Aidan Pine", email = "hello@aidanpine.ca" }, + { name = "Samuel Larkin", email = "Samuel.Larkin@nrc-cnrc.gc.ca" }, + { name = "Eric Joanis", email = "Eric.Joanis@nrc-cnrc.gc.ca" }, + { name = "Mengzhe Geng", email = "Mengzhe.Geng@nrc-cnrc.gc.ca" }, +] +maintainers = [ + { name = "Aidan Pine", email = "Aidan.Pine@nrc-cnrc.gc.ca" }, + { name = "Samuel Larkin", email = "Samuel.Larkin@nrc-cnrc.gc.ca" }, + { name = "Eric Joanis", email = "Eric.Joanis@nrc-cnrc.gc.ca" }, +] +classifiers = [ + "License :: OSI Approved :: MIT License", + "Operating System :: OS Independent", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3.10", + "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", + "Development Status :: 3 - Alpha", + "Topic :: Multimedia :: Sound/Audio :: Speech", +] +dependencies = ["everyvoice==0.3.*"] + +[project.scripts] +fs2l = "fs2.cli:app" + +[project.urls] +Homepage = "https://github.com/EveryVoiceTTS/FastSpeech2_lightning" + +[tool.hatch.version] +path = "fs2/_version.py" + +[tool.hatch.build.targets.sdist] +include = ["/fs2"] + +[tool.hatch.build.targets.wheel] +include = ["/fs2"] + +[project.optional-dependencies] +dev = ["everyvoice[dev]"] diff --git a/requirements.dev.txt b/requirements.dev.txt deleted file mode 100644 index 4b6ee75..0000000 --- a/requirements.dev.txt +++ /dev/null @@ -1,13 +0,0 @@ -# This is a set of development dependencies -black~=24.3 -flake8>=4.0.1 -gitlint-core==0.17.0 -isort>=5.10.1 -matplotlib-stubs==0.2.0 -mypy>=1.8.0 -pre-commit>=3.2.0 -types-pyyaml>=6.0.5 -types-requests>=2.27.11 -types-setuptools>=57.4.9 -types-tabulate==0.8.11 -types-tqdm>=4.64,<5.0 diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index 879913e..0000000 --- a/requirements.txt +++ /dev/null @@ -1 +0,0 @@ -everyvoice==0.2.* diff --git a/setup.py b/setup.py deleted file mode 100644 index 2f42b4c..0000000 --- a/setup.py +++ /dev/null @@ -1,45 +0,0 @@ -""" Setup for FastSpeech2 -""" - -import datetime as dt -from os import path - -from setuptools import find_packages, setup - -build_no = dt.datetime.now().strftime("%Y%m%d") - -# Ugly hack to read the current version number without importing g2p: -# (works by ) -VERSION = "0.0" + "." + build_no - -this_directory = path.abspath(path.dirname(__file__)) - -with open(path.join(this_directory, "readme.md"), encoding="utf8") as f: - long_description = f.read() - -with open(path.join(this_directory, "requirements.txt"), encoding="utf8") as f: - REQS = f.read().splitlines() - -setup( - name="fs2l", - python_requires=">=3.10", - version=VERSION, - author="Aidan Pine", - author_email="hello@aidanpine.ca", - license="MIT", - url="https://github.com/EveryVoiceTTS/FastSpeech2_lightning", - description="Text-to-Speech Synthesis for the Speech Generation for Indigenous Language Education Small Teams Project", - long_description=long_description, - long_description_content_type="text/markdown", - platform=["any"], - packages=find_packages(), - include_package_data=True, - install_requires=REQS, - entry_points={"console_scripts": ["fs2l = fs2.cli:app"]}, - zip_safe=False, - classifiers=[ - "Programming Language :: Python :: 3", - "License :: OSI Approved :: MIT License", - "Operating System :: OS Independent", - ], -) From cc5d9f3be831cd12800422956aeb9ab49d6eeac1 Mon Sep 17 00:00:00 2001 From: Eric Joanis Date: Fri, 7 Feb 2025 15:03:06 -0500 Subject: [PATCH 2/3] docs: add URLs to pyproject.toml Co-authored-by: Samuel Larkin --- pyproject.toml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 6cb5fc9..afa45c6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -37,6 +37,8 @@ fs2l = "fs2.cli:app" [project.urls] Homepage = "https://github.com/EveryVoiceTTS/FastSpeech2_lightning" +Repository = "https://github.com/EveryVoiceTTS/FastSpeech2_lightning" +Issues = "https://github.com/EveryVoiceTTS/FastSpeech2_lightning/issues" [tool.hatch.version] path = "fs2/_version.py" From 3a1a7e07bae5651047ac19f7dae5a41cc95cb753 Mon Sep 17 00:00:00 2001 From: Eric Joanis Date: Tue, 11 Feb 2025 11:46:54 -0500 Subject: [PATCH 3/3] fix: match EV major.minor version --- fs2/_version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs2/_version.py b/fs2/_version.py index 1cf6267..867e4b1 100644 --- a/fs2/_version.py +++ b/fs2/_version.py @@ -1 +1 @@ -VERSION = "0.1.0" +VERSION = "0.3.0"