Skip to main content

Client for the library of Roubaix (Médiathèque Roubaix)

Project description

MediathequeRoubaix.py

Python CLI for the library of Roubaix (Médiathèque Roubaix)

PyPI PyPI - Python Version PyPI - License


Releases: https://github.com/tomsquest/mediathequeroubaix.py/releases

Source Code: https://github.com/tomsquest/mediathequeroubaix.py

PyPI: https://pypi.org/project/mediathequeroubaix/


Table of Contents

Features

MédiathèqueRoubaix.py is a client for the libray of Roubaix, mediathequederoubaix.fr.

Screenshot mediathequederoubaix.fr

Display your loans

Running mediathequeroubaix loans list will:

  1. Get the list of your loans and their due date
  2. ...for many cardholders
  3. and check the next return date for each of your card

Renew your loans

Running mediathequeroubaix loans renew will:

  1. Renew automatically all loans
  2. ...for many cardholders
  3. and print the new due date of the loans

Usage

Running

With Pipx:

pipx run mediathequederoubaix

With UV:

uvx mediathequederoubaix

If you want to install it globally:

pipx install mediathequeroubaix

Create an initial, sample configuration

config create makes a sample configuration in $HOME/.config/mediathequederoubaix/config.json and display the content of the file.
The configuration is initialized with a sample but fake user.

mediathequeroubaix config create

Screenshot CLI config create

Display the current configuration

config show displays the current configuration.

mediathequeroubaix config show

Screenshot CLI config show

List the loans

loans list show the list of loans for the users.

mediathequeroubaix loans list

Screenshot CLI loans list

Renew the loans

loans renew renew the list of loans for the users and display the new loans.

mediathequeroubaix loans renew

Screenshot CLI loans renew

Why I am doing this

I created this project to:

  1. Learn Functional Programing
  2. Learn typed and modern Python
  3. Be able to quickly list and renew my loans (especially when you have many cards)

Changelog

See CHANGELOG.md

Development

  • Clone this repository
  • Install UV
  • (Optional) if using direnv, create .envrc with:
uv sync
source .venv/bin/activate
  • Testing
pytest
  • Check everything in one go
pre-commit run --all-files

Releasing

Trigger the Draft release workflow (press Run workflow). This will update the changelog & version and create a GitHub release which is in Draft state.

Find the draft release from the GitHub releases and publish it. When a release is published, it'll trigger release workflow which creates PyPI release.

Credits

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mediathequeroubaix-1.5.0.tar.gz (616.5 kB view details)

Uploaded Source

Built Distribution

mediathequeroubaix-1.5.0-py3-none-any.whl (17.9 kB view details)

Uploaded Python 3

File details

Details for the file mediathequeroubaix-1.5.0.tar.gz.

File metadata

  • Download URL: mediathequeroubaix-1.5.0.tar.gz
  • Upload date:
  • Size: 616.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.4.29

File hashes

Hashes for mediathequeroubaix-1.5.0.tar.gz
Algorithm Hash digest
SHA256 74fa6a6031630395c047c5e51860dc3dd5f5b96e3ff9da2d190bc719a766320f
MD5 f233e8b926b4db279d9fa7d2eb5b9bfb
BLAKE2b-256 422508a3afb6c85be7d151e60e3e03be85133feeb54cad9ad893acff8f49cfed

See more details on using hashes here.

File details

Details for the file mediathequeroubaix-1.5.0-py3-none-any.whl.

File metadata

File hashes

Hashes for mediathequeroubaix-1.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f0862990a58873c91b57efdde191631cccf120987e5f5207fce3a8f68dc4f541
MD5 f5540c0bba9834ca5fc34b6c34ba34a9
BLAKE2b-256 7c00d447c49733f9239e0d8deef8a6d7fe512b3227c35fd75bfcab753082b0b4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page