Skip to content

Repository files navigation

Flibusta Downloader

A Tkinter-based application for downloading and merging story parts from the Flibusta website into a single EPUB file.

Project Setup

Prerequisites

  • Python 3.7 or higher
  • Git (for cloning the repository)

Initial Setup (After Clone)

When you first clone this repository, follow these steps to set up the virtual environment:

  1. Create the virtual environment:

    python -m venv .venv
  2. Activate the virtual environment:

    .\.venv\Scripts\Activate.ps1

    If you get an execution policy error, you may need to run:

    Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
  3. Install dependencies:

    pip install -r requirements.txt

Updating Python Version

If you need to update to a newer version of Python, follow these steps:

  1. Deactivate the current virtual environment (if activated):

    deactivate
  2. Remove the old virtual environment:

    rmdir .venv -Recurse -Force
  3. Install the new Python version from python.org or your package manager.

  4. Recreate the virtual environment with the new Python version:

    python -m venv .venv
  5. Activate the new virtual environment:

    .\.venv\Scripts\Activate.ps1
  6. Reinstall dependencies:

    pip install -r requirements.txt

Running the Application

Using the Batch File (Recommended)

Simply double-click run.bat to execute the script. This will:

  • Activate the virtual environment
  • Run flibusta_downloader.py

Alternatively, run from PowerShell:

.\run.bat

Using the Command Line

Activate the virtual environment and run the script manually:

.\.venv\Scripts\Activate.ps1
python .\flibusta_downloader.py

Or run it directly with the Python executable from .venv:

.\.venv\Scripts\python.exe .\flibusta_downloader.py

Dependencies

The project requires the following Python packages (listed in requirements.txt):

  • requests - HTTP library for fetching web pages
  • beautifulsoup4 - HTML/XML parsing library
  • six - Python 2 and 3 compatibility utilities (required by epubmerge)

Additionally, the project uses:

  • epubmerge - Local module for merging EPUB files (located in ../EpubMerge/)

Project Structure

.
├── flibusta_downloader.py    # Main application script
├── test_python.py             # Test file
├── run.bat                     # Batch script to run the application
├── requirements.txt            # Python dependencies
├── README.md                   # This file
├── .venv/                      # Virtual environment (created after setup)
├── output/                     # Downloaded EPUB files
├── data.json                   # Data file
└── [story_folders]/            # Organized story directories

Usage

  1. Launch the application using run.bat or manually run the script
  2. Enter the Flibusta story URL in the interface
  3. (Optional) Enter the last update date to filter for new parts
  4. Select which story parts to download
  5. Click "Save story epub" to download and merge the selected parts
  6. The merged EPUB file will be saved to the output/ folder

Troubleshooting

Module not found errors

Make sure you have activated the virtual environment and installed all dependencies:

.\.venv\Scripts\Activate.ps1
pip install -r requirements.txt

Permission denied on .venv\Scripts\Activate.ps1

Run this command to allow script execution:

Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser

Python version incompatibility

Check your Python version:

python --version

If needed, follow the "Updating Python Version" section above.

Logging

The application logs its activity to flibusta_downloader.log in the project root directory. Check this file for debugging information.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages