Vinyl2Digital is a Python3 pip package for batch rendering multiple audio files using the Audacity mod-script-pipe. Perfect for digitizing vinyl records, cassettes, or any multi-track audio recordings.
# Install
pip install vinyl2digital
# Update
pip install --upgrade vinyl2digital
# Test connection
python -m vinyl2digital -t
pip install vinyl2digital
Windows (Command Prompt Admin):
cd "C:\Program Files\Audacity"
start audacity.exe
macOS/Linux:
open -a Audacity
# or
audacity
- Record your audio and splice each track into its own selection
- Place cursor at the start of each track and press
Ctrl+I
(orCmd+I
on Mac) - Set export quality by going to
File β Export β Export Selected Audio
- these settings will be used by vinyl2digital - Move cursor to the start of your recording
While Audacity is open, test your connection:
python -m vinyl2digital -t
You should see confirmation that both pipes exist and are working.
python -m vinyl2digital -i [input] -f [format] -o [output_path]
python -m vinyl2digital -i discogs [discogs_url] -f flac -o "path/to/output"
python -m vinyl2digital -i 12 -f mp3 -o "path/to/output"
Flag | Description |
---|---|
-h |
View help page |
-t |
Test connection to Audacity mod-script-pipe |
Flag | Description |
---|---|
-i discogs [url] |
Use Discogs URL for track count and metadata |
-i [number] |
Export specified number of tracks with default filenames |
Flag | Description |
---|---|
-f flac |
Export as FLAC audio files |
-f mp3 |
Export as MP3 audio files |
-f wav |
Export as WAV audio files |
Flag | Description |
---|---|
-o "path" |
Set output directory path |
python -m vinyl2digital -i discogs https://www.discogs.com/release/2019460-Various-The-New-England-Teen-Scene -f flac -o "E:\rips\vinyl\NewEnglandTeenScene"
python -m vinyl2digital -i 5 -f mp3 -o "E:\rips\vinyl\MyAlbum"
python -m vinyl2digital -i 7 -f flac -o "E:\martinradio\rips\cassette\Art Foxall β Art's Back In Town [1987, Cassette]"
git clone https://github.com/MartinBarker/vinyl2digital.git
cd vinyl2digital
Create Virtual Environment:
# Create a new virtual environment
python -m venv venv
Activate Virtual Environment:
Windows (Command Prompt):
venv\Scripts\activate
Windows (PowerShell):
venv\Scripts\Activate.ps1
macOS/Linux:
source venv/bin/activate
Note: You'll know the virtual environment is active when you see (venv)
at the beginning of your command prompt.
# Install the package in editable mode for local development
pip install -e .
# This allows you to modify the code and see changes immediately
# without reinstalling the package
# Check if the package is installed
pip list | grep vinyl2digital
# View package information including version
pip show vinyl2digital
# Run the package to see help
python -m vinyl2digital -h
# Test the package functionality
python -m vinyl2digital -t
deactivate
os
,sys
,requests
,json
,time
,re
This project uses GitHub Actions for automated building and publishing to PyPI. Here's how to release a new version:
Edit setup.py
and increment the version number:
setup(
name="vinyl2digital",
version="1.0.7", # β Update this
# ... rest of setup
)
# Commit your changes
git add .
git commit -m "Bump version to 1.0.7"
# Create and push a new tag
git tag v1.0.7
git push origin main --tags
The GitHub Actions workflow will automatically:
- Build the distribution packages (wheel and source tarball)
- Publish to TestPyPI on every push (for testing)
- Publish to PyPI when you push a tag (for releases)
- Check the Actions tab in your GitHub repository
- Verify the workflow completed successfully
- Check PyPI for your new version
If you prefer to release manually:
# Build the package
python -m pip install --upgrade build
python -m build
# Upload to PyPI
pip install twine
python -m twine upload dist/*
vinyl2digital/
βββ .github/
β βββ workflows/
β βββ publish-to-pypi.yml # GitHub Actions workflow
βββ vinyl2digital/
β βββ __init__.py # Main package code
β βββ __main__.py # Entry point
βββ setup.py # Package configuration
βββ README.md # This file
βββ LICENSE # License information
- "Both pipes exist. Good." - Connection is working correctly
- "..does not exist. Ensure Audacity is running with mod-script-pipe" - Enable mod-script-pipe in Audacity
- Files not appearing in expected location - Check the detailed output logs for exact file paths
- Check the PyPI project page
- Review the command line help:
python -m vinyl2digital -h
- Ensure Audacity is running with mod-script-pipe enabled
This project is licensed under the MIT License - see the LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.
Made with β€οΈ for the vinyl digitization community