Skip to main content

A CLI tool to display useful Python recipes.

Project description

Pyrecipes

ci workflow Publish Pyrecipes to PyPI coverage-badge


Recipes from Python Cookbook, Third Edition, by David Beazley and Brian K. Jones. Copyright © 2013 David Beazley and Brian Jones. Published by O'Reilly Media, Inc. Used with permission.

This project implements a simple CLI tool to list, run and view these recipes.

Special thanks to O'Reilly Media, Inc and the Authors for permission to use their recipes.

Check out Author David Beazley's website: https://www.dabeaz.com/

Add this amazing book to your bookshelf here

Python Cookbook


Installation

pip install pyrecipes

Example Usage

Show recipes help and subcommands

recipes

List all chapters

recipes chapters

List all recipes

recipes ls

List all recipes in a specific chapter

recipes ls 1

List all recipes in a specific chapter with a short description

recipes ls 1 -d

Show recipe code

recipes show 1 3

Run the recipe as a script

recipes run 1 3

Search for recipes containing a pattern

RegEx is supported.

recipes search 'itertools'
recipes search 'itertools' --color green
recipes search 'event' --ignore-case
recipes search 'functools' -c
recipes search '[a-z]\d[^\s]'

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

pyrecipes-0.3.2.tar.gz (2.3 MB view details)

Uploaded Source

Built Distribution

pyrecipes-0.3.2-py3-none-any.whl (2.4 MB view details)

Uploaded Python 3

File details

Details for the file pyrecipes-0.3.2.tar.gz.

File metadata

  • Download URL: pyrecipes-0.3.2.tar.gz
  • Upload date:
  • Size: 2.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for pyrecipes-0.3.2.tar.gz
Algorithm Hash digest
SHA256 e5a6b88aa5c2dc7878c8d5ff4f58753ec20b3bca5b1425cd8f384183b000ac43
MD5 de7323b5b158daf4ea204b6cff3ea0d4
BLAKE2b-256 56d80ea0f8ec043a9e09cbe55f5dc9b88b45b7e01788175f4a60184b59c2d6f2

See more details on using hashes here.

File details

Details for the file pyrecipes-0.3.2-py3-none-any.whl.

File metadata

  • Download URL: pyrecipes-0.3.2-py3-none-any.whl
  • Upload date:
  • Size: 2.4 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for pyrecipes-0.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 5db03485950e20f682bacbebd765c98729b4ea21b6f5f50e7b72528ccf9e4e48
MD5 1d620994eb354af089833ed43baecdac
BLAKE2b-256 2c488c57f2d05e55fd8eacbff99d762199a559785fd7c42755d9e166fef9739e

See more details on using hashes here.

Supported by

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