.. image:: https://img.shields.io/pypi/v/CueParser.svg
:alt: PyPI version shields.io
:target: https://pypi.python.org/pypi/CueParser/
CueParser
=========
Simple cue file parser and generator written in python.
Parser outputs cue file content in plain text. Generator can create cue file from timed tracklist.
Installation
============
**$ pip install CueParser**
Usage
=====
::
usage: cueparser.py [-h] [-H HEADER] [-t TRACK] file
::
positional arguments:
file path to cue file
optional arguments:
-h, --help show this help message and exit
-H HEADER, --header HEADER
header output template
-t TRACK, --track TRACK
track output template
::
usage: cuegen.py [-h] [-p PERFORMER] [-t TITLE] [-a AUDIO_FILE] [-e AUDIO_FILE_EXT] [-f FILE]
::
options:
-h, --help show this help message and exit
-p PERFORMER, --performer PERFORMER
PERFORMER
-t TITLE, --title TITLE
TITLE
-a AUDIO_FILE, --audio_file AUDIO_FILE
FILE
-e AUDIO_FILE_EXT, --audio_file_ext AUDIO_FILE_EXT
FILE EXTENSION
-f FILE, --file FILE path to tracklist file
Example
=======
**$ cueparser.py file.cue**
will output content with such template:
* for header: %performer% - %title%\\n%file%\\n%tracks% (also can be %format%, %rem%, %songwriter%)
* for tracks: %performer% - %title% (also can be %cuetime%, %offset%, %index%, %songwriter%)
**$ cuegen.py -f file.txt**
will create cue file from tracklist looks like:
[00:00] Artist 1 - Title 1
[03:00] Artist 2 - Title 2
etc...
or it can generate cuesheet from audacity labels file:
0.000000 1.000000 Artist 1 - Label 1
2.500000 4.200000 Artist 2 - Label 2
6.800000 8.000000 Artist 3 - Label 3
Library example
===============
.. code:: python
cuesheet = CueSheet()
cuesheet.setOutputFormat(args.header, args.track)
with open(cuefile, "r") as f:
cuesheet.setData(f.read())
cuesheet.parse()
print(cuesheet.output())
Raw data
{
"_id": null,
"home_page": "https://github.com/artur-shaik/CueParser",
"name": "CueParser",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "cue parser cdtool audio generator",
"author": "Artur Shaik",
"author_email": "ashaihullin@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/ea/4e/81bc39e71edd72c1e3b9422aca525f937753df920e7930ec42575c8aaf66/CueParser-1.3.1.tar.gz",
"platform": null,
"description": ".. image:: https://img.shields.io/pypi/v/CueParser.svg\n :alt: PyPI version shields.io\n :target: https://pypi.python.org/pypi/CueParser/\n\nCueParser\n=========\n\nSimple cue file parser and generator written in python. \nParser outputs cue file content in plain text. Generator can create cue file from timed tracklist.\n\nInstallation\n============\n\n**$ pip install CueParser**\n\nUsage\n=====\n\n:: \n\n usage: cueparser.py [-h] [-H HEADER] [-t TRACK] file\n\n::\n\n positional arguments:\n file path to cue file\n\n optional arguments:\n -h, --help show this help message and exit\n -H HEADER, --header HEADER\n header output template\n -t TRACK, --track TRACK\n track output template\n\n:: \n\n usage: cuegen.py [-h] [-p PERFORMER] [-t TITLE] [-a AUDIO_FILE] [-e AUDIO_FILE_EXT] [-f FILE]\n\n::\n\n options:\n -h, --help show this help message and exit\n -p PERFORMER, --performer PERFORMER\n PERFORMER\n -t TITLE, --title TITLE\n TITLE\n -a AUDIO_FILE, --audio_file AUDIO_FILE\n FILE\n -e AUDIO_FILE_EXT, --audio_file_ext AUDIO_FILE_EXT\n FILE EXTENSION\n -f FILE, --file FILE path to tracklist file\n\nExample\n=======\n\n**$ cueparser.py file.cue**\n\nwill output content with such template: \n\n* for header: %performer% - %title%\\\\n%file%\\\\n%tracks% (also can be %format%, %rem%, %songwriter%) \n* for tracks: %performer% - %title% (also can be %cuetime%, %offset%, %index%, %songwriter%)\n\n**$ cuegen.py -f file.txt**\n\nwill create cue file from tracklist looks like:\n\n [00:00] Artist 1 - Title 1\n\n [03:00] Artist 2 - Title 2\n\n etc...\n\nor it can generate cuesheet from audacity labels file:\n\n 0.000000 1.000000 Artist 1 - Label 1\n 2.500000 4.200000 Artist 2 - Label 2\n 6.800000 8.000000 Artist 3 - Label 3\n\nLibrary example\n===============\n\n.. code:: python \n\n cuesheet = CueSheet()\n cuesheet.setOutputFormat(args.header, args.track) \n with open(cuefile, \"r\") as f: \n cuesheet.setData(f.read())\n\n cuesheet.parse()\n print(cuesheet.output())\n",
"bugtrack_url": null,
"license": "",
"summary": "Simple cue file parser.",
"version": "1.3.1",
"project_urls": {
"Homepage": "https://github.com/artur-shaik/CueParser"
},
"split_keywords": [
"cue",
"parser",
"cdtool",
"audio",
"generator"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "255618693d65307fd13cae994a28f6e0f9c10dd7e4c86db33b692285845aadde",
"md5": "9cd919d939e1357a357c73ebf73dafa8",
"sha256": "2de8a9f7af331723bfc9976e16d47c4f55e1991f12a478ccb9a11514f716ec47"
},
"downloads": -1,
"filename": "CueParser-1.3.1-py2.py3-none-any.whl",
"has_sig": false,
"md5_digest": "9cd919d939e1357a357c73ebf73dafa8",
"packagetype": "bdist_wheel",
"python_version": "py2.py3",
"requires_python": null,
"size": 7058,
"upload_time": "2023-11-03T05:55:51",
"upload_time_iso_8601": "2023-11-03T05:55:51.681718Z",
"url": "https://files.pythonhosted.org/packages/25/56/18693d65307fd13cae994a28f6e0f9c10dd7e4c86db33b692285845aadde/CueParser-1.3.1-py2.py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "ea4e81bc39e71edd72c1e3b9422aca525f937753df920e7930ec42575c8aaf66",
"md5": "5b8529dae1ac1185fdfb5b7ab7364d8b",
"sha256": "c7d6bd75ffb6189adba7ee65c305d484305095a00f1a8930813e2d082a1a651d"
},
"downloads": -1,
"filename": "CueParser-1.3.1.tar.gz",
"has_sig": false,
"md5_digest": "5b8529dae1ac1185fdfb5b7ab7364d8b",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 6232,
"upload_time": "2023-11-03T05:55:53",
"upload_time_iso_8601": "2023-11-03T05:55:53.339766Z",
"url": "https://files.pythonhosted.org/packages/ea/4e/81bc39e71edd72c1e3b9422aca525f937753df920e7930ec42575c8aaf66/CueParser-1.3.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-11-03 05:55:53",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "artur-shaik",
"github_project": "CueParser",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "cueparser"
}