mirror of
https://github.com/iluvcapra/ptulsconv.git
synced 2025-12-31 08:50:48 +00:00
Compare commits
17 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 32191791c6 | |||
| 1ff910e4d2 | |||
| 0e8a77f548 | |||
|
|
7058397f6f | ||
|
|
16d7befd9f | ||
|
|
2a3f4a7c18 | ||
| d7fff23e5e | |||
|
|
757c3171e7 | ||
| 48dd7de07e | |||
|
|
dc259d54aa | ||
| 2a69bf47c8 | |||
| 01d2374a9b | |||
| 68e7eb89a9 | |||
|
|
517fe3526a | ||
| 7789c0df4c | |||
| d97dcc3e08 | |||
| 615b2b5a2a |
4
.flake8
4
.flake8
@@ -1,4 +0,0 @@
|
|||||||
[flake8]
|
|
||||||
per-file-ignores =
|
|
||||||
src/ptulsconv/__init__.py: F401
|
|
||||||
src/ptulsconv/docparser/__init__.py: F401
|
|
||||||
11
.github/workflows/python-package.yml
vendored
11
.github/workflows/python-package.yml
vendored
@@ -27,14 +27,11 @@ jobs:
|
|||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
python -m pip install --upgrade pip
|
python -m pip install --upgrade pip
|
||||||
python -m pip install flake8 pytest
|
pip install .
|
||||||
pip install -e .
|
pip install --group dev .
|
||||||
- name: Lint with flake8
|
- name: Lint with ruff
|
||||||
run: |
|
run: |
|
||||||
# stop the build if there are Python syntax errors or undefined names
|
ruff check src
|
||||||
flake8 src/ptulsconv tests --count --select=E9,F63,F7,F82 --show-source --statistics
|
|
||||||
# exit-zero treats all errors as warnings.
|
|
||||||
flake8 src/ptulsconv tests --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
|
|
||||||
- name: Test with pytest
|
- name: Test with pytest
|
||||||
run: |
|
run: |
|
||||||
pytest
|
pytest
|
||||||
|
|||||||
@@ -10,10 +10,15 @@ build:
|
|||||||
os: ubuntu-20.04
|
os: ubuntu-20.04
|
||||||
tools:
|
tools:
|
||||||
python: "3.10"
|
python: "3.10"
|
||||||
# You can also specify other tool versions:
|
jobs:
|
||||||
# nodejs: "16"
|
pre_install:
|
||||||
# rust: "1.55"
|
- pip install --upgrade --upgrade-strategy only-if-needed --group doc .
|
||||||
# golang: "1.17"
|
build:
|
||||||
|
html:
|
||||||
|
python -m sphinx -T -b html -d _build/doctrees -D language=en . $READTHEDOCS_OUTPUT/html
|
||||||
|
post_build:
|
||||||
|
- echo "Command run at 'post_build' step"
|
||||||
|
- echo `date`
|
||||||
|
|
||||||
# Build documentation in the docs/ directory with Sphinx
|
# Build documentation in the docs/ directory with Sphinx
|
||||||
sphinx:
|
sphinx:
|
||||||
@@ -23,10 +28,13 @@ sphinx:
|
|||||||
formats:
|
formats:
|
||||||
- pdf
|
- pdf
|
||||||
|
|
||||||
|
# FIXME: We should be installing the `doc` dependency group and not the `doc`
|
||||||
|
# extra.
|
||||||
|
|
||||||
#Optionally declare the Python requirements required to build your docs
|
#Optionally declare the Python requirements required to build your docs
|
||||||
python:
|
# python:
|
||||||
install:
|
# install:
|
||||||
- method: pip
|
# - method: pip
|
||||||
path: .
|
# path: .
|
||||||
extra_requirements:
|
# extra_requirements:
|
||||||
- doc
|
# - doc
|
||||||
|
|||||||
@@ -22,7 +22,11 @@ For a quick overview of how to cue ADR with `ptulsconv`, check out the [Quicksta
|
|||||||
The easiest way to install on your site is to use `pip`:
|
The easiest way to install on your site is to use `pip`:
|
||||||
|
|
||||||
% pip3 install ptulsconv
|
% pip3 install ptulsconv
|
||||||
|
|
||||||
|
If you are using `uv` you can also do a tool install...
|
||||||
|
|
||||||
|
% uv tool install ptulsconv
|
||||||
|
|
||||||
This will install the necessary libraries on your host and gives you
|
This will install the necessary libraries on your host and gives you
|
||||||
command-line access to the tool through an entry-point `ptulsconv`. In a
|
command-line access to the tool through an entry-point `ptulsconv`. In a
|
||||||
terminal window type `ptulsconv -h` for a list of available options.
|
terminal window type `ptulsconv -h` for a list of available options.
|
||||||
|
|||||||
@@ -4,7 +4,8 @@ version = "4.0.0"
|
|||||||
description = "Read Pro Tools Text exports and generate PDF ADR Reports, JSON"
|
description = "Read Pro Tools Text exports and generate PDF ADR Reports, JSON"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
requires-python = ">=3.9"
|
requires-python = ">=3.9"
|
||||||
license = { file = "LICENSE" }
|
|
||||||
|
license-files = ["LICENSE"]
|
||||||
keywords = ["text-processing", "parsers", "film",
|
keywords = ["text-processing", "parsers", "film",
|
||||||
"broadcast", "editing", "editorial"]
|
"broadcast", "editing", "editorial"]
|
||||||
classifiers = [
|
classifiers = [
|
||||||
@@ -27,6 +28,9 @@ dependencies = [
|
|||||||
"tqdm>=4.67.1",
|
"tqdm>=4.67.1",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
# [tool.uv.build-backend]
|
||||||
|
# data = { headers = "include/headers", scripts = "bin" }
|
||||||
|
|
||||||
[project.urls]
|
[project.urls]
|
||||||
Source = 'https://github.com/iluvcapra/ptulsconv'
|
Source = 'https://github.com/iluvcapra/ptulsconv'
|
||||||
Issues = 'https://github.com/iluvcapra/ptulsconv/issues'
|
Issues = 'https://github.com/iluvcapra/ptulsconv/issues'
|
||||||
@@ -48,5 +52,9 @@ build-backend = "uv_build"
|
|||||||
|
|
||||||
[dependency-groups]
|
[dependency-groups]
|
||||||
dev = [
|
dev = [
|
||||||
"flake8>=7.3.0",
|
"ruff>=0.13.1",
|
||||||
|
]
|
||||||
|
doc = [
|
||||||
|
"sphinx>=7.4.7",
|
||||||
|
"sphinx-rtd-theme>=3.0.2",
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -55,8 +55,8 @@ def output_adr_csv(lines: List[ADRLine], time_format: TimecodeFormat):
|
|||||||
directories for each character number and name pair, and within that
|
directories for each character number and name pair, and within that
|
||||||
directory, creates a CSV file for each reel.
|
directory, creates a CSV file for each reel.
|
||||||
"""
|
"""
|
||||||
reels = set([ln.reel for ln in lines])
|
|
||||||
|
|
||||||
|
reels: set[str | None] = set([ln.reel for ln in lines])
|
||||||
for n, name in [(n.character_id, n.character_name) for n in lines]:
|
for n, name in [(n.character_id, n.character_name) for n in lines]:
|
||||||
dir_name = "%s_%s" % (n, name)
|
dir_name = "%s_%s" % (n, name)
|
||||||
os.makedirs(dir_name, exist_ok=True)
|
os.makedirs(dir_name, exist_ok=True)
|
||||||
|
|||||||
@@ -2,4 +2,7 @@
|
|||||||
Docparser module
|
Docparser module
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
|
||||||
from .pt_doc_parser import parse_document
|
from .pt_doc_parser import parse_document
|
||||||
|
|
||||||
|
__all__ = [parse_document]
|
||||||
|
|||||||
@@ -79,13 +79,13 @@ def make_doc_template(page_size, filename, document_title,
|
|||||||
header_box, page_box = page_box.split_y(0.75 * inch, direction='d')
|
header_box, page_box = page_box.split_y(0.75 * inch, direction='d')
|
||||||
title_box, report_box = header_box.split_x(3.5 * inch, direction='r')
|
title_box, report_box = header_box.split_x(3.5 * inch, direction='r')
|
||||||
|
|
||||||
on_page_lambda = (lambda c, _:
|
def on_page_lambda(c, _):
|
||||||
draw_header_footer(c, report_box, title_box,
|
draw_header_footer(c, report_box, title_box,
|
||||||
footer_box, title=title,
|
footer_box, title=title,
|
||||||
supervisor=supervisor,
|
supervisor=supervisor,
|
||||||
document_subheader=document_subheader,
|
document_subheader=document_subheader,
|
||||||
client=client,
|
client=client,
|
||||||
doc_title=document_header))
|
doc_title=document_header)
|
||||||
|
|
||||||
frames = [Frame(page_box.min_x, page_box.min_y,
|
frames = [Frame(page_box.min_x, page_box.min_y,
|
||||||
page_box.width, page_box.height)]
|
page_box.width, page_box.height)]
|
||||||
|
|||||||
Reference in New Issue
Block a user