From charlesreid1

(Created page with "First step is to create the top-level directory that all the code related to this thing will live. I'll call it <code>myproject</code> Now in myproject we create <code>setup.py...")
 
No edit summary
Line 1: Line 1:
First step is to create the top-level directory that all the code related to this thing will live.
<pre>
 
myproject/
I'll call it <code>myproject</code>
    setup.py
 
    myproject/
Now in myproject we create <code>setup.py</code>:
        __init__.py
        code.py
        submodule/
            somecode.py
            morecode.py
</pre>


==Setup.py==
<pre>
<pre>
try:
try:

Revision as of 00:44, 19 March 2015

myproject/
    setup.py
    myproject/
        __init__.py
        code.py
        submodule/
            somecode.py
            morecode.py


Setup.py

try:
    from setuptools import setup
except ImportError:
    from distutils.core import setup

config = {
    'description': 'My Project',
    'author': 'My Name',
    'url': 'URL to get it at.',
    'download_url': 'Where to download it.',
    'author_email': 'My email.',
    'version': '0.1',
    'install_requires': ['nose'],
    'packages': ['NAME'],
    'scripts': [],
    'name': 'projectname'
}

setup(**config)