Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: CI

on:
push:
branches: [ master, main ]
pull_request:
branches: [ master, main ]

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .

- name: Test imports
run: |
python -c "import dmx; print('✓ dmx imported successfully')"
python -c "import dmx.cli; print('✓ dmx.cli imported successfully')"
python -c "import dmx.interactive; print('✓ dmx.interactive imported successfully')"
python -c "import dmx.music_client; print('✓ dmx.music_client imported successfully')"

- name: Test CLI help
run: |
python -m dmx --help

- name: Run basic tests (if they exist)
run: |
if [ -d "tests" ] && [ -n "$(ls -A tests/)" ]; then
pip install pytest
pytest tests/
else
echo "No tests found, skipping test execution"
fi
48 changes: 48 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Publish to PyPI

on:
release:
types: [published]
workflow_dispatch: # Allow manual trigger

jobs:
build-and-publish:
runs-on: ubuntu-latest

steps:
- name: Checkout code
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: Build package
run: |
python -m build

- name: Check package
run: |
twine check dist/*

- name: Publish to Test PyPI
if: github.event_name == 'workflow_dispatch'
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.TEST_PYPI_API_TOKEN }}
run: |
twine upload --repository testpypi dist/*

- name: Publish to PyPI
if: github.event_name == 'release'
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: |
twine upload dist/*
7 changes: 7 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
include README.md
include LICENSE
include MANIFEST.in
include pyproject.toml
recursive-exclude * __pycache__
recursive-exclude * *.py[co]
recursive-exclude * *.DS_Store
83 changes: 69 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,36 @@
# dmx
# dmx - Interactive Music Search & Download

Simple music search and download tool using deemix.
Interactive music search and download tool with Deezer integration. Browse artists, view their profiles, and download albums directly from the command line.

## Features
## Features

- **Interactive Search**: Search for tracks, albums, and artists on Deezer
- **Quality Downloads**: Automatic quality fallback (320kbps → 128kbps)
### 🎵 **Advanced Artist Browsing**
- **Artist Search & Profiles**: Search artists and view detailed profiles with top songs
- **Complete Album Collections**: Browse ALL albums from any artist (sorted by popularity)
- **Direct Album Downloads**: Download any album by simply typing its number
- **Smart Sorting**: Artists sorted by fan count for better discovery

### 🎯 **Interactive Experience**
- **Multi-Mode Search**: Switch between tracks, albums, and artists instantly
- **Intuitive Navigation**: Browse artist profiles with `back` command support
- **Visual Feedback**: Color-coded interface with progress indicators
- **Smart Detection**: Avoids re-downloading existing files
- **Clean Interface**: Minimal, colorful command-line interface

### ⚡ **Quality & Performance**
- **Quality Downloads**: Automatic quality fallback (320kbps → 128kbps → available)
- **Batch Operations**: Efficient album downloads with progress tracking
- **ARL Authentication**: Secure authentication using Deezer ARL tokens
- **Cross-Platform**: Works on Windows, macOS, and Linux

## Installation
## 📦 Installation

### Using Nix (Recommended)
### Using pip (Recommended)

```bash
pip install dmx-music
```

### Using Nix

```bash
# Install directly from GitHub
Expand All @@ -24,12 +42,6 @@ nix run github:cargaona/dmx
}
```

### Using pip

```bash
pip install dmx
```

### From source

```bash
Expand Down Expand Up @@ -60,6 +72,49 @@ pip install -e .
[tracks] > 1 # Download first result
```

## 🎨 Artist Browsing Workflow

**Featured in v0.1.0**: Complete artist profile browsing with album downloads

```bash
# Switch to artists mode
[tracks] > m artists

# Search for artists (sorted by fan count)
[artists] > pez

# View artist profile
[artists] > 2 # Select Pez with 10,580 fans

# Browse ALL artist albums (72 total)
[Pez Albums] > l # List all albums

# Download any album directly
[Pez Albums] > 15 # Download album #15

# Navigate back
[Pez Albums] > back
[artists] >
```

### Example Artist Profile:
```
🎤 Artist Profile
Pez
72 albums • 10,580 fans

🎵 Top Songs:
Aire al Fin
El Manto Eléctrico • 3:13

💿 Albums (Enter number to download):
1 Goodbye Dear, Ok Chicago. (11 tracks)
2 Ion (13 tracks)
[... 70 more albums ...]

Commands: [number] = download album | 'back' = return to artist search
```

## Usage

### Interactive Mode (Default)
Expand Down
90 changes: 90 additions & 0 deletions RELEASE_CHECKLIST.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
# Release Checklist for dmx-music

Use this checklist when preparing a new release.

## Pre-Release Setup (One-time)

- [ ] Create PyPI account at https://pypi.org/account/register/
- [ ] Create Test PyPI account at https://test.pypi.org/account/register/
- [ ] Generate PyPI API token at https://pypi.org/manage/account/#api-tokens
- [ ] Generate Test PyPI API token at https://test.pypi.org/manage/account/#api-tokens
- [ ] Add `PYPI_API_TOKEN` to GitHub repository secrets
- [ ] Add `TEST_PYPI_API_TOKEN` to GitHub repository secrets

## For Each Release

### 1. Prepare Release
- [ ] Update version in `pyproject.toml`
```toml
version = "0.1.x" # Increment appropriately
```
- [ ] Update `RELEASE_NOTES.md` with new features and changes
- [ ] Test the package locally:
```bash
pip install -e .
dmx --help # Should work
```
- [ ] Commit all changes to main/master branch

### 2. Create GitHub Release
- [ ] Go to repository → Releases → "Create a new release"
- [ ] Tag version: `v0.1.x` (matching pyproject.toml)
- [ ] Release title: `dmx-music v0.1.x`
- [ ] Description: Copy relevant sections from `RELEASE_NOTES.md`
- [ ] Click "Publish release"

### 3. Monitor Automated Publishing
- [ ] Go to Actions tab in GitHub
- [ ] Watch "Publish to PyPI" workflow
- [ ] Verify it completes successfully (green checkmark)
- [ ] Check https://pypi.org/project/dmx-music/ for new version

### 4. Verify Publication
- [ ] Test installation from PyPI:
```bash
pip install dmx-music==0.1.x
dmx --help
dmx-music --help
```
- [ ] Test basic functionality:
```bash
dmx # Should start interactive mode
# Try: m artists, search for artist, etc.
```

### 5. Post-Release
- [ ] Update README.md if needed with any installation changes
- [ ] Announce release (if desired)
- [ ] Plan next version features

## Manual Testing (Optional)

If you want to test on Test PyPI first:

- [ ] Go to Actions → "Publish to PyPI" → "Run workflow" → Run
- [ ] This publishes to Test PyPI only
- [ ] Test install: `pip install --index-url https://test.pypi.org/simple/ dmx-music`
- [ ] If successful, proceed with GitHub release for production PyPI

## Version Strategy

- **0.1.x**: Initial releases, bug fixes, small improvements
- **0.2.x**: New major features (playlist support, etc.)
- **0.x.x**: API changes, significant new functionality
- **1.0.0**: Stable API, production ready

## Quick Commands

```bash
# Check current version
grep version pyproject.toml

# Test local build
python -m build

# Check package quality
twine check dist/*

# View recent releases
gh release list # if you have GitHub CLI
```
Loading
Loading