Skip to content

Instantly share code, notes, and snippets.

@medwards
Created April 12, 2012 10:04
Show Gist options
  • Save medwards/2366194 to your computer and use it in GitHub Desktop.
Save medwards/2366194 to your computer and use it in GitHub Desktop.
Adding custom commands to python setup.py
from setuptools import Command
class Compile(Command):
description = "run a custom compile command"
user_options = tuple()
def run(self):
print self.description
def initialize_options(self):
pass
def finalize_options(self):
pass
entry_points = {
"distutils.commands" : [ "compile = package.commands:Compile" ]
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment