ttsfm / .github /workflows /release.yml
NitinBot001's picture
Upload 38 files
3ca5f72 verified
name: Release and Publish
on:
push:
tags:
- 'v*' # Triggers on version tags like v1.0.0, v3.0.1, etc.
permissions:
contents: write
id-token: write
jobs:
release-and-publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build twine
- name: Test package import
run: |
pip install -e .
python -c "import ttsfm; print(f'βœ… TTSFM imported successfully')"
python -c "from ttsfm import TTSClient; print('βœ… TTSClient imported successfully')"
- name: Build package
run: |
python -m build
echo "πŸ“¦ Package built successfully"
ls -la dist/
- name: Check package
run: |
twine check dist/*
echo "βœ… Package validation passed"
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
attestations: true
skip-existing: true
- name: Extract version (strip leading v)
id: ver
run: echo "version=${GITHUB_REF_NAME#v}" >> "$GITHUB_OUTPUT"
- name: Create GitHub Release
uses: softprops/action-gh-release@v1
with:
body: |
## πŸŽ‰ TTSFM ${{ github.ref_name }}
New release of TTSFM - Free Text-to-Speech API with OpenAI compatibility.
### πŸ“¦ Installation
```bash
pip install ttsfm==${{ steps.ver.outputs.version }}
```
### πŸš€ Quick Start
```python
from ttsfm import TTSClient
client = TTSClient()
response = client.generate_speech("Hello from TTSFM!")
response.save_to_file("hello")
```
### 🐳 Docker
```bash
docker run -p 8000:8000 dbcccc/ttsfm:latest
```
### ✨ Features
- πŸ†“ Completely free (uses openai.fm service)
- 🎯 OpenAI-compatible API
- πŸ—£οΈ 11 voices available
- 🎡 6 audio formats (MP3, WAV, OPUS, AAC, FLAC, PCM)
- ⚑ Async and sync clients
- 🌐 Web interface included
- πŸ”§ CLI tool available
### πŸ“š Documentation
See [README](https://github.com/dbccccccc/ttsfm#readme) for full documentation.
draft: false
prerelease: false