mirror of
https://github.com/iluvcapra/ptulsconv.git
synced 2025-12-31 17:00:46 +00:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
22edecdbbf | ||
|
|
7c8a74aed9 | ||
|
|
96a4cdb612 | ||
|
|
8720087bb2 | ||
|
|
f734aae227 | ||
|
|
17e9c77ed7 | ||
|
|
fc7dde8fd6 | ||
|
|
3021721299 | ||
|
|
cf9be9abf1 | ||
|
|
73936510cd | ||
|
|
d118554443 | ||
|
|
22c205d638 | ||
|
|
36ac320b44 |
29
.github/workflows/pythonpublish.yml
vendored
Normal file
29
.github/workflows/pythonpublish.yml
vendored
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
name: Upload Python Package
|
||||||
|
|
||||||
|
on:
|
||||||
|
release:
|
||||||
|
types: [created]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v1
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v1
|
||||||
|
with:
|
||||||
|
python-version: '3.x'
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
python -m pip install --upgrade pip
|
||||||
|
pip install setuptools wheel twine
|
||||||
|
- name: Install parsimonious
|
||||||
|
run: |
|
||||||
|
pip install parsimonious
|
||||||
|
- name: Build and publish
|
||||||
|
env:
|
||||||
|
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
|
||||||
|
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
|
||||||
|
run: |
|
||||||
|
python setup.py sdist bdist_wheel
|
||||||
|
twine upload dist/*
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
language: python
|
language: python
|
||||||
python:
|
python:
|
||||||
- "3.7"
|
- "3.7"
|
||||||
|
- "3.8
|
||||||
script:
|
script:
|
||||||
- "python -m unittest discover tests"
|
- "python -m unittest discover tests"
|
||||||
install:
|
install:
|
||||||
|
|||||||
@@ -110,8 +110,3 @@ A clip name beginning with "&" will have its parsed clip name appended to the pr
|
|||||||
cues will be applied (later clips having precedence). The clips need not be touching, and the clips will be combined
|
cues will be applied (later clips having precedence). The clips need not be touching, and the clips will be combined
|
||||||
into a single row of the output. The start time of the first clip will become the start time of the row, and the finish
|
into a single row of the output. The start time of the first clip will become the start time of the row, and the finish
|
||||||
time of the last clip will become the finish time of the row.
|
time of the last clip will become the finish time of the row.
|
||||||
|
|
||||||
## Other Projects
|
|
||||||
|
|
||||||
This project is under construction. Look at [Pro Tools Text](https://github.com/iluvcapra/ProToolsText)
|
|
||||||
for a working solution at this time.
|
|
||||||
|
|||||||
@@ -2,6 +2,6 @@ from .ptuls_grammar import protools_text_export_grammar
|
|||||||
from .ptuls_parser_visitor import DictionaryParserVisitor
|
from .ptuls_parser_visitor import DictionaryParserVisitor
|
||||||
from .transformations import TimecodeInterpreter
|
from .transformations import TimecodeInterpreter
|
||||||
|
|
||||||
__version__ = '0.1.0'
|
__version__ = '0.3.3'
|
||||||
__author__ = 'Jamie Hardt'
|
__author__ = 'Jamie Hardt'
|
||||||
__license__ = 'MIT'
|
__license__ = 'MIT'
|
||||||
|
|||||||
@@ -1,4 +0,0 @@
|
|||||||
#!/bin/zsh
|
|
||||||
python3 setup.py build
|
|
||||||
python3 setup.py sdist bdist_wheel
|
|
||||||
python3 -m twine upload --repository-url https://upload.pypi.org/legacy/ dist/*
|
|
||||||
3
setup.py
3
setup.py
@@ -24,12 +24,13 @@ setup(name='ptulsconv',
|
|||||||
'Topic :: Multimedia',
|
'Topic :: Multimedia',
|
||||||
'Topic :: Multimedia :: Sound/Audio',
|
'Topic :: Multimedia :: Sound/Audio',
|
||||||
"Programming Language :: Python :: 3.7",
|
"Programming Language :: Python :: 3.7",
|
||||||
|
"Programming Language :: Python :: 3.8",
|
||||||
"Development Status :: 4 - Beta",
|
"Development Status :: 4 - Beta",
|
||||||
"Topic :: Text Processing :: Filters",
|
"Topic :: Text Processing :: Filters",
|
||||||
"Topic :: Text Processing :: Markup :: XML"],
|
"Topic :: Text Processing :: Markup :: XML"],
|
||||||
packages=['ptulsconv'],
|
packages=['ptulsconv'],
|
||||||
keywords='text-processing parsers film tv editing editorial',
|
keywords='text-processing parsers film tv editing editorial',
|
||||||
install_requires=['parsimonious','tqdm'],
|
install_requires=['parsimonious', 'tqdm'],
|
||||||
entry_points={
|
entry_points={
|
||||||
'console_scripts': [
|
'console_scripts': [
|
||||||
'ptulsconv = ptulsconv.__main__:main'
|
'ptulsconv = ptulsconv.__main__:main'
|
||||||
|
|||||||
@@ -6,6 +6,31 @@ class TaggingIntegratedTests(unittest.TestCase):
|
|||||||
|
|
||||||
path = os.path.dirname(__file__) + '/export_cases/Tag Tests/Tag Tests.txt'
|
path = os.path.dirname(__file__) + '/export_cases/Tag Tests/Tag Tests.txt'
|
||||||
|
|
||||||
|
def test_event_list(self):
|
||||||
|
with open(self.path, 'r') as f:
|
||||||
|
visitor = ptulsconv.DictionaryParserVisitor()
|
||||||
|
result = ptulsconv.protools_text_export_grammar.parse(f.read())
|
||||||
|
parsed: dict = visitor.visit(result)
|
||||||
|
|
||||||
|
tcxform = ptulsconv.transformations.TimecodeInterpreter()
|
||||||
|
tagxform = ptulsconv.transformations.TagInterpreter(show_progress=False,
|
||||||
|
ignore_muted=True,
|
||||||
|
log_output=False)
|
||||||
|
|
||||||
|
parsed = tcxform.transform(parsed)
|
||||||
|
parsed = tagxform.transform(parsed)
|
||||||
|
|
||||||
|
self.assertEqual(9, len(parsed['events']))
|
||||||
|
self.assertEqual("Clip Name", parsed['events'][0]['PT.Clip.Name'])
|
||||||
|
self.assertEqual("Lorem ipsum" , parsed['events'][1]['PT.Clip.Name'])
|
||||||
|
self.assertEqual("Dolor sic amet the rain in spain" , parsed['events'][2]['PT.Clip.Name'])
|
||||||
|
self.assertEqual("A B C" , parsed['events'][3]['PT.Clip.Name'])
|
||||||
|
self.assertEqual("Silver Bridge" , parsed['events'][4]['PT.Clip.Name'])
|
||||||
|
self.assertEqual("Region 02" , parsed['events'][5]['PT.Clip.Name'])
|
||||||
|
self.assertEqual("Region 12" , parsed['events'][6]['PT.Clip.Name'])
|
||||||
|
self.assertEqual("Region 22" , parsed['events'][7]['PT.Clip.Name'])
|
||||||
|
self.assertEqual("Region 04" , parsed['events'][8]['PT.Clip.Name'])
|
||||||
|
|
||||||
def test_append(self):
|
def test_append(self):
|
||||||
with open(self.path, 'r') as f:
|
with open(self.path, 'r') as f:
|
||||||
visitor = ptulsconv.DictionaryParserVisitor()
|
visitor = ptulsconv.DictionaryParserVisitor()
|
||||||
|
|||||||
Reference in New Issue
Block a user