3

I have a bunch of commands that I want to distribute to my colleagues. They want me to package it and add it to their path (/usr/local/bin)

How would I do this? We already have a Python repository. Is this possible in an egg?

Belmin Fernandez
  • 8,307
  • 9
  • 51
  • 75

2 Answers2

4

I dislike answering my own question but I have begun looking at this:

http://docs.python.org/distutils/setupscript.html#installing-additional-files

Seems like it might be the answer. I will update this answer when I try it out on Monday. Or, if anyone has used something like this before, answer yourself!

Belmin Fernandez
  • 8,307
  • 9
  • 51
  • 75
  • 2
    +1, but it's good idea to use `distutils2` or `setuptools` instead of `distutils` which are going to be deprecated. See more details on packaging library selection here: http://stackoverflow.com/questions/6344076/differences-between-distribute-distutils-and-setuptools – Alexander Lebedev Apr 06 '12 at 20:52
  • Thanks. Seems like this could be of great help and I will check it out on Monday: http://packages.python.org/distribute/setuptools.html#automatic-script-creation – Belmin Fernandez Apr 06 '12 at 21:16
0

One option would be to build an RPM. This is generally a pretty convenient way to install files to a predefined location.

Andrew Clark
  • 202,379
  • 35
  • 273
  • 306