chore(audiobook_library): add project files

This commit is contained in:
Lucas Vivo committed 2026-11-21 14:57:30 +01:00
1 parent dac70a632c
commit cdad6a5dca
5 files changed
+102

No files matched your search

+26
View File
@@ -0,0 +1,26 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "audiobook_library: Run sample command",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/main.py",
"args": [],
"cwd": "${workspaceFolder}",
"python": "${workspaceFolder}/.venv/bin/python3",
"console": "integratedTerminal",
"justMyCode": true
},
{
"name": "audiobook_library: Run tests",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/run_tests.py",
"cwd": "${workspaceFolder}",
"python": "${workspaceFolder}/.venv/bin/python3",
"console": "integratedTerminal",
"justMyCode": true
}
]
}
+32
View File
@@ -0,0 +1,32 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "audiobook_library: Run tests",
"type": "process",
"command": "${workspaceFolder}/.venv/bin/python3",
"args": [
"run_tests.py"
],
"options": {
"cwd": "${workspaceFolder}"
},
"group": "test",
"problemMatcher": []
},
{
"label": "audiobook_library: Build package",
"type": "process",
"command": "uv",
"args": ["build"],
"options": {
"cwd": "${workspaceFolder}"
},
"group": {
"kind": "build",
"isDefault": false
},
"problemMatcher": []
}
]
}
+12
View File
@@ -0,0 +1,12 @@
## CI
The Gitea workflow runs the test suite with generated synthetic media and
database fixtures, and lints with Ruff. On pushes to `main`, it builds a
standalone executable and installs it to `~/tools/audiobook_library` on the
same runners used by ffmpeg_handling. FFmpeg and ffprobe must be available
on the target host.
To run the suite locally, use `python run_tests.py`. It uses `test/assets` by
default; set `AUDIOBOOK_TEST_ASSETS` to use another fixture directory. CI
fixtures can be generated with `python test/create_ci_fixtures.py <directory>`.
Do not commit private audiobook or database fixtures.
+8
View File
@@ -0,0 +1,8 @@
#!/usr/bin/env python3
import sys
from audiobook_library.cli import main
if __name__ == "__main__":
sys.exit(main())
+24
View File
@@ -0,0 +1,24 @@
[project]
name = "audiobook-library"
version = "0.1.0"
description = "Add your description here"
readme = "README.md"
authors = [
{ name = "Lucas Vivo", email = "lucas@mediahost" }
]
requires-python = ">=3.12"
dependencies = [
"mutagen>=1.47.0",
"requests>=2.33.1",
"serverlibrary",
]
[project.scripts]
audiobook-library = "audiobook_library:main"
[build-system]
requires = ["uv_build>=0.12.19,<0.13.0"]
build-backend = "uv_build"
[tool.uv.sources]
serverlibrary = { path = "../serverlibrary" }