Skip to main content
Warning: You are using the test version of PyPI. This is a pre-production deployment of Warehouse. Changes made here affect the production instance of TestPyPI (testpypi.python.org).
Help us improve Python packaging - Donate today!

Quickly open Python modules in your text editor.

Project Description

Quickly open Python modules in your text editor.

$ ped django
$ ped django.core.urlresolvers
$ ped django.views.generic.TemplateView

# Partial name matching
$ ped django.http.resp
Editing django.http.response...
...Done.

# Specify which editor to use
$ PED_EDITOR=vim ped django.shortcuts

ped will find your modules in the currently-active virtual environment.

Get it now

$ pip install ped

Changing the default editor

ped will try to use your favorite text editor. If you want to override the editor ped uses, set the PED_EDITOR environment variable.

# .zshrc or .bashrc
# Use Sublime Text with ped
export PED_EDITOR=subl

Tab-completion

The ped package contains tab-completion scripts for bash and zsh. Place these files in your system’s completion directories. The ped.install_completion module can be run as a script to copy the files.

Bash completion

To install bash completion, run:

# The path given here will depend on your OS
$ python -m ped.install_completion --bash /usr/local/etc/bash_completion.d

Zsh completion

To install zsh completion, run:

# The path given here will depend on your OS
$ python -m ped.install_completion --zsh /usr/local/share/zsh/site-functions

Editor integrations

Kudos

This was inspired by IPython’s %edit magic.

Changelog

1.5.0

1.4.0

  • Add --info argument for outputting name, file path, and line number of modules/functions/classes.
  • Fix: Support line numbers in gvim.

1.3.0

  • If a class or function is passed, the editor will open up the file at the correct line number (for supported editors).

1.2.1

  • Fix for Py2 compatibility.

1.2.0

  • Add partial name matching.

1.1.0

  • Add support for editing functions and classes.

1.0.2

  • Fix for editing subpackages, e.g. ped pkg.subpkg.
Release History

Release History

This version
History Node

1.5.0

History Node

1.5.0.dev0

History Node

1.4.0

History Node

1.3.0

History Node

1.2.1

History Node

1.2.0.dev0

History Node

1.1.0

History Node

1.0.2

History Node

1.0.0

Download Files

Download Files

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

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
ped-1.5.0.tar.gz (9.4 kB) Copy SHA256 Checksum SHA256 Source Sep 10, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting