Skip to main content

Tool to pip install missing imports and more

Project description

Tool to pip install missing imports and more

Build Status

https://img.shields.io/travis/yahoo/pipr.svg https://coveralls.io/repos/yahoo/pipr/badge.svg https://img.shields.io/pypi/dm/pipr.svg https://img.shields.io/pypi/v/pipr.svg https://img.shields.io/pypi/pyversions/pipr.svg https://img.shields.io/badge/license-New%20BSD-blue.svg Documentation Status

Description

pipr can install missing dependencies for any Python file and generate a requirements.txt file, so that YOU don’t have to worry about searching for and installing the dependencies manually

Requirements

pipr supports both Python 2.7, and Python 3.4

Installation

To install pipr, simply:

$ pip install pipr

Usage

$ pipr -h
usage: pipr [-h] [-r] [-d] [-R] filepath

positional arguments:
filepath            The path to the Python file

optional arguments:
    -h, --help          show this help message and exit
    -r, --requirements  Add --requirements to generate a requirements.txt
                        file in current directory
    -d, --debug         Add --debug to see debug output
    -R, --recursive     Add --recursive to handle project-wide dependency
$ cat test.py
import argparse
import sshmap, redislite
import urllib2
import sbi
# import commentimp
from time import sleep
'''
import commentimp2
'''

$ pipr test.py -d -r
Imported packages: argparse, sshmap, redislite, urllib2, sbi, time
Missing packages installed: sshmap==0.6.90, sbi==0.0.7

Because we added -r, there will a requirements.txt file generated in the current directory.

More Information

Project details


Download files

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

Files for pipr, version 0.0.50
Filename, size File type Python version Upload date Hashes
Filename, size pipr-0.0.50-py2.py3-none-any.whl (10.9 kB) File type Wheel Python version py2.py3 Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page