Kristian Glass - Do I Smell Burning?

Mostly technical things

Using Pipenv on Read the Docs

I really like Read the Docs - a great documentation hosting platform, free for open source and community projects.

I really like Pipenv for managing my Python project dependencies.

Unfortunately Read the Docs have decided to not support Pipenv. This is perfectly reasonable of them - it’s their service, and everything they decide to support incurs a cost. Alas it’s not quite ideal for me!

Fortunately both tools provide useful compatibility features that make it pretty straightforward to get them working together:

  1. Read the Docs will let you run commands before dependencies are installed with build.jobs.pre_install
  2. Pipenv will generate a requirements.txt with pipenv requirements

So all you need to do is add the following to your .readthedocs.yaml and off you go:

build:
  jobs:
    pre_install:
      - "pip install pipenv"
      - "pipenv requirements > requirements.txt"

(See it in action)

Comments