From f0412f8a481ab77bc6f53c283ea8125bef4f1c1b Mon Sep 17 00:00:00 2001 From: baxtree Date: Mon, 15 Jan 2024 09:15:34 +0000 Subject: [PATCH] add recommendation on WSL for Windows users --- MANIFEST.in | 5 ++++- README.md | 3 ++- setup.py | 9 +++++++-- site/source/advanced_usage.rst | 4 ++-- site/source/installation.rst | 4 ++-- site/source/usage.rst | 4 ++-- 6 files changed, 19 insertions(+), 10 deletions(-) diff --git a/MANIFEST.in b/MANIFEST.in index 540b720..c79193b 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1 +1,4 @@ -include requirements.txt \ No newline at end of file +graft subaligner +include pyproject.toml +include setup.py +global-exclude *.py[cod] \ No newline at end of file diff --git a/README.md b/README.md index c918464..9391f8e 100644 --- a/README.md +++ b/README.md @@ -75,7 +75,8 @@ If you prefer using a containerised environment over installing everything local ``` $ docker run -v `pwd`:`pwd` -w `pwd` -it baxtree/subaligner bash ``` -For users on Windows 10: [Docker Desktop](https://docs.docker.com/docker-for-windows/install/) is the only option at present. +For Windows users, you can use Windows Subsystem for Linux ([WSL](https://learn.microsoft.com/en-us/windows/wsl/install)) to install Subaligner. +Alternatively, you can use [Docker Desktop](https://docs.docker.com/docker-for-windows/install/) to pull and run the image. Assuming your media assets are stored under `d:\media`, open built-in command prompt, PowerShell, or Windows Terminal and run: ``` docker pull baxtree/subaligner diff --git a/setup.py b/setup.py index fb8e5b0..8cb48d4 100644 --- a/setup.py +++ b/setup.py @@ -66,13 +66,18 @@ def get_tag(self): "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Intended Audience :: Developers", + "Topic :: Utilities", ], license="MIT", - url="https://subaligner.readthedocs.io/en/latest/", + url="https://github.com/baxtree/subaligner", description="Automatically synchronize and translate subtitles, or create new ones by transcribing, using pre-trained DNNs, Forced Alignments and Transformers.", long_description=readme + "\n\n", long_description_content_type="text/markdown", - python_requires=">=3.8", + project_urls={ + "Documentation": "https://subaligner.readthedocs.io/en/latest/", + "Source": "https://github.com/baxtree/subaligner", + }, + python_requires=">=3.8,<3.12", wheel=True, package_dir={"subaligner": "subaligner"}, packages=[ diff --git a/site/source/advanced_usage.rst b/site/source/advanced_usage.rst index c49f424..9b9e051 100644 --- a/site/source/advanced_usage.rst +++ b/site/source/advanced_usage.rst @@ -129,8 +129,8 @@ flags to customise the configuration on tuning: For output subtitles like MicroDVD relying on the frame rate, its value needs to be passed in with `-fr` or `--frame_rate`. -**On Windows**:: +**On Windows with Docker Desktop**:: docker run -v "/d/media":/media -w "/media" -it baxtree/subaligner COMMAND -The aforementioned commands can be run with `Docker Desktop `_ on Windows 10. \ No newline at end of file +The aforementioned commands can be run with `Docker Desktop `_ on Windows. Nonetheless, it is recommended to use Windows Subsystem for Linux (`WSL `_) to install Subaligner. \ No newline at end of file diff --git a/site/source/installation.rst b/site/source/installation.rst index e85391f..fc2ec3a 100644 --- a/site/source/installation.rst +++ b/site/source/installation.rst @@ -79,10 +79,10 @@ to create a virtual environment and set up all the dependencies: (.venv) $ subaligner_train --help (.venv) $ subaligner_tune --help -**On Windows**:: +**On Windows with Docker Desktop**:: docker pull baxtree/subaligner docker run -v "/d/media":/media -w "/media" -it baxtree/subaligner bash Assuming that your media assets are stored under "d:\\media", open built-in command prompt, PowerShell, or Windows Terminal and run the above. -`Docker Desktop `_ is the only option at present for Windows users. +`Docker Desktop `_ is the only option at present for Windows users. Nonetheless, it is recommended to use Windows Subsystem for Linux (`WSL `_) to install Subaligner. diff --git a/site/source/usage.rst b/site/source/usage.rst index 67fc637..daf3dea 100644 --- a/site/source/usage.rst +++ b/site/source/usage.rst @@ -97,11 +97,11 @@ or `--stretch_on` as shown below. (.venv) $ subaligner -m dual -v video.mp4 -s subtitle.srt -o /path/to/the/output/subtitle.srt -**On Windows**:: +**On Windows with Docker Desktop**:: docker run -v "/d/media":/media -w "/media" -it baxtree/subaligner COMMAND -The aforementioned commands can be run with `Docker Desktop `_ on Windows 10. +The aforementioned commands can be run with `Docker Desktop `_ on Windows. Nonetheless, it is recommended to use Windows Subsystem for Linux (`WSL `_) to install Subaligner. **Re-configure FFmpeg/Libav path**::