Skip to content

julianpistorius/doit-tutorial

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Playing with doit

See the doit tutorial

Note: This code is for the instructions up to the section on 'clean'.

  • Complete the rest of the tutorial

To use this code

  1. Install pipenv (if you don't already have it):
brew install pipenv
  1. Install graphviz:
brew install graphviz
  1. Install the dependencies by running the following in the same directory as the Pipfile file:
pipenv install
  1. Activate the virtual environment:
pipenv shell
  1. Run the doit workflow:
doit

You should see something like:

$ doit
.  imports
.  dot
.  draw
  1. Check that the files were created:
ls -l requests*

You should see something like:

$ ls -l requests*
-rw-r--r--  1 johndoe  staff    164 Mar  4 10:28 requests.models.deps
-rw-r--r--  1 johndoe  staff    404 Mar  4 10:28 requests.models.dot
-rw-r--r--  1 johndoe  staff  37154 Mar  4 10:28 requests.models.png
  1. Check that the requests.models.png looks like the one in the tutorial.

Exercises for the reader

  • Add a task which creates the projects directory
  • Add a task which clones the requests repository into the projects directory