awesome-python icon indicating copy to clipboard operation
awesome-python copied to clipboard

Sort README entries alphabetically

Open mehmetdogandev opened this issue 5 months ago • 1 comments

Summary

This PR adds an automated sorting script that organizes README entries alphabetically, making it easier for users to find Python libraries and for maintainers to manage the list.

Motivation

The current README has libraries scattered throughout sections without alphabetical order, making it difficult for users to quickly locate specific tools. This script automates the sorting process and maintains consistency.

Key Features

  • 🔤 Alphabetical Sorting: Automatically sorts all library entries within their categories
  • 📄 PDF Generation: Creates professional PDF versions for offline reading
  • 🏗️ Structure Preservation: Maintains existing README structure and formatting
  • 🔧 Cross-platform: Works on Windows, macOS, and Linux
  • 📱 Multiple Output Formats: Supports ReportLab PDF and HTML-to-PDF conversion

Files Added/Modified

  • sort.py - Main sorting script with comprehensive documentation
  • requirements.txt - Added dependencies for PDF generation
  • mkdocs.yml - Updated configuration for PDF export capability
  • README.md - Sorted all entries alphabetically while preserving structure
  • docs/css/pdf.css - Styling for PDF generation

Technical Implementation

  • Dual Sorting Approach: Line-based and section-based sorting algorithms
  • Indentation-Aware: Preserves nested list structures
  • Link-Safe Processing: Maintains all markdown links and descriptions
  • Error Handling: Comprehensive error checking and user feedback

Usage Examples

# Basic README sorting
python sort.py

# Generate professional PDF
python sort.py --pdf

# Create HTML for browser-based PDF conversion
python sort.py --html

mehmetdogandev avatar Jul 04 '25 05:07 mehmetdogandev

Thanks @poteakshay241

mehmetdogandev avatar Jul 11 '25 12:07 mehmetdogandev