diff options
author | Ask Solem <askh@modwheel.net> | 2009-03-17 11:10:19 +0100 |
---|---|---|
committer | Ask Solem Hoel <askh@opera.com> | 2009-03-17 11:10:19 +0100 |
commit | 1f2bd3cb54ccde0946c9efba6a8fc279c03ea878 (patch) | |
tree | 2273dbd9b6f1700ff7af24112095c9d254b8e184 | |
parent | f13cdf62b1f48900bbd7850d0ea5f331eb5d5302 (diff) | |
download | chishop-1f2bd3cb54ccde0946c9efba6a8fc279c03ea878.tar.bz2 chishop-1f2bd3cb54ccde0946c9efba6a8fc279c03ea878.tar.xz chishop-1f2bd3cb54ccde0946c9efba6a8fc279c03ea878.zip |
Better project layout, now setup.py installs djangopypi
-rw-r--r-- | MANIFEST.in | 1 | ||||
-rw-r--r-- | chishop/djangopypi/__init__.py | 0 | ||||
-rwxr-xr-x | chishop/media/_ | 0 | ||||
-rwxr-xr-x | chishop/media/dists/django-greystripe-0.1.tar.gz | bin | 4653 -> 0 bytes | |||
-rwxr-xr-x | chishop/media/foo.txt | 0 | ||||
-rw-r--r-- | chishop/settings.py | 37 | ||||
-rw-r--r-- | djangopypi/__init__.py | 33 | ||||
-rw-r--r-- | djangopypi/admin.py (renamed from chishop/djangopypi/admin.py) | 0 | ||||
-rw-r--r-- | djangopypi/forms.py (renamed from chishop/djangopypi/forms.py) | 0 | ||||
-rw-r--r-- | djangopypi/models.py (renamed from chishop/djangopypi/models.py) | 0 | ||||
-rw-r--r-- | djangopypi/templates/djangopypi/show_links.html (renamed from chishop/djangopypi/templates/djangopypi/show_links.html) | 0 | ||||
-rw-r--r-- | djangopypi/templates/djangopypi/show_version.html (renamed from chishop/djangopypi/templates/djangopypi/show_version.html) | 0 | ||||
-rw-r--r-- | djangopypi/templates/djangopypi/simple.html (renamed from chishop/djangopypi/templates/djangopypi/simple.html) | 0 | ||||
-rw-r--r-- | djangopypi/views.py (renamed from chishop/djangopypi/views.py) | 0 | ||||
-rw-r--r-- | setup.py | 4 |
15 files changed, 59 insertions, 16 deletions
diff --git a/MANIFEST.in b/MANIFEST.in index 45e2f40..9ab6242 100644 --- a/MANIFEST.in +++ b/MANIFEST.in | |||
@@ -2,4 +2,5 @@ include AUTHORS | |||
2 | include README | 2 | include README |
3 | include TODO | 3 | include TODO |
4 | include MANIFEST.in | 4 | include MANIFEST.in |
5 | recursive-include djangopypi * | ||
5 | recursive-include manifest * | 6 | recursive-include manifest * |
diff --git a/chishop/djangopypi/__init__.py b/chishop/djangopypi/__init__.py deleted file mode 100644 index e69de29..0000000 --- a/chishop/djangopypi/__init__.py +++ /dev/null | |||
diff --git a/chishop/media/_ b/chishop/media/_ deleted file mode 100755 index e69de29..0000000 --- a/chishop/media/_ +++ /dev/null | |||
diff --git a/chishop/media/dists/django-greystripe-0.1.tar.gz b/chishop/media/dists/django-greystripe-0.1.tar.gz deleted file mode 100755 index bef3dd7..0000000 --- a/chishop/media/dists/django-greystripe-0.1.tar.gz +++ /dev/null | |||
Binary files differ | |||
diff --git a/chishop/media/foo.txt b/chishop/media/foo.txt deleted file mode 100755 index e69de29..0000000 --- a/chishop/media/foo.txt +++ /dev/null | |||
diff --git a/chishop/settings.py b/chishop/settings.py index 8c18760..2ff0103 100644 --- a/chishop/settings.py +++ b/chishop/settings.py | |||
@@ -1,28 +1,38 @@ | |||
1 | # Django settings for djangopypi project. | 1 | # Django settings for djangopypi project. |
2 | import os | 2 | import os |
3 | 3 | ||
4 | DEBUG = True | 4 | # #### |
5 | TEMPLATE_DEBUG = DEBUG | 5 | # This are the settings you're most likely to change |
6 | LOCAL_DEVELOPMENT = True | 6 | # when running the chishop servber. |
7 | 7 | ||
8 | if LOCAL_DEVELOPMENT: | 8 | # If this is true errors will have informative error pages. |
9 | import os | 9 | DEBUG = True |
10 | import sys | ||
11 | sys.path.append(os.path.dirname(__file__)) | ||
12 | 10 | ||
13 | ADMINS = ( | 11 | ADMINS = ( |
14 | # ('Your Name', 'your_email@domain.com'), | 12 | # ('Your Name', 'your_email@domain.com'), |
15 | ) | 13 | ) |
16 | 14 | ||
17 | MANAGERS = ADMINS | 15 | # Absolute path to the directory that holds media. |
16 | # Example: "/home/media/media.lawrence.com/" | ||
17 | # Uploaded python distributions will be saved in the | ||
18 | # dists/ directory under this path. | ||
19 | here = os.path.abspath(os.path.dirname(__file__)) | ||
20 | MEDIA_ROOT = os.path.join(here, 'media') | ||
21 | |||
22 | |||
23 | # Database settings. | ||
18 | 24 | ||
19 | DATABASE_ENGINE = 'sqlite3' | 25 | DATABASE_ENGINE = 'sqlite3' # or mysql |
20 | DATABASE_NAME = 'devdatabase.db' | 26 | DATABASE_NAME = 'devdatabase.db' |
21 | DATABASE_USER = '' | 27 | DATABASE_USER = '' |
22 | DATABASE_PASSWORD = '' | 28 | DATABASE_PASSWORD = '' |
23 | DATABASE_HOST = '' | 29 | DATABASE_HOST = '' |
24 | DATABASE_PORT = '' | 30 | DATABASE_PORT = '' |
25 | 31 | ||
32 | |||
33 | # ###### --- settings below here, are probably not that important ---- ##### | ||
34 | |||
35 | |||
26 | # Local time zone for this installation. Choices can be found here: | 36 | # Local time zone for this installation. Choices can be found here: |
27 | # http://en.wikipedia.org/wiki/List_of_tz_zones_by_name | 37 | # http://en.wikipedia.org/wiki/List_of_tz_zones_by_name |
28 | # although not all choices may be available on all operating systems. | 38 | # although not all choices may be available on all operating systems. |
@@ -34,16 +44,15 @@ TIME_ZONE = 'America/Chicago' | |||
34 | # http://www.i18nguy.com/unicode/language-identifiers.html | 44 | # http://www.i18nguy.com/unicode/language-identifiers.html |
35 | LANGUAGE_CODE = 'en-us' | 45 | LANGUAGE_CODE = 'en-us' |
36 | 46 | ||
47 | MANAGERS = ADMINS | ||
48 | TEMPLATE_DEBUG = DEBUG | ||
49 | LOCAL_DEVELOPMENT = DEBUG | ||
37 | SITE_ID = 1 | 50 | SITE_ID = 1 |
38 | 51 | ||
39 | # If you set this to False, Django will make some optimizations so as not | 52 | # If you set this to False, Django will make some optimizations so as not |
40 | # to load the internationalization machinery. | 53 | # to load the internationalization machinery. |
41 | USE_I18N = True | 54 | USE_I18N = True |
42 | 55 | ||
43 | # Absolute path to the directory that holds media. | ||
44 | # Example: "/home/media/media.lawrence.com/" | ||
45 | here = os.path.abspath(os.path.dirname(__file__)) | ||
46 | MEDIA_ROOT = os.path.join(here, 'media') | ||
47 | 56 | ||
48 | # URL that handles the media served from MEDIA_ROOT. Make sure to use a | 57 | # URL that handles the media served from MEDIA_ROOT. Make sure to use a |
49 | # trailing slash if there is a path component (optional in other cases). | 58 | # trailing slash if there is a path component (optional in other cases). |
diff --git a/djangopypi/__init__.py b/djangopypi/__init__.py new file mode 100644 index 0000000..148c185 --- /dev/null +++ b/djangopypi/__init__.py | |||
@@ -0,0 +1,33 @@ | |||
1 | """ djangopypi.py | ||
2 | Copyright (c) 2009, Ask Solem | ||
3 | All rights reserved. | ||
4 | |||
5 | Redistribution and use in source and binary forms, with or without | ||
6 | modification, are permitted provided that the following conditions are met: | ||
7 | |||
8 | * Redistributions of source code must retain the above copyright notice, | ||
9 | this list of conditions and the following disclaimer. | ||
10 | * Redistributions in binary form must reproduce the above copyright | ||
11 | notice, this list of conditions and the following disclaimer in the | ||
12 | documentation and/or other materials provided with the distribution. | ||
13 | |||
14 | Neither the name of Ask Solem nor the names of its contributors may be used | ||
15 | to endorse or promote products derived from this software without specific | ||
16 | prior written permission. | ||
17 | |||
18 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
19 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, | ||
20 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | ||
21 | PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS | ||
22 | BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
23 | CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
24 | SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
25 | INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
26 | CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
27 | ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE | ||
28 | POSSIBILITY OF SUCH DAMAGE. | ||
29 | |||
30 | """ | ||
31 | |||
32 | VERSION = (0, 1, 0) | ||
33 | __version__ = ".".join(map(str, VERSION)) | ||
diff --git a/chishop/djangopypi/admin.py b/djangopypi/admin.py index 30290e0..30290e0 100644 --- a/chishop/djangopypi/admin.py +++ b/djangopypi/admin.py | |||
diff --git a/chishop/djangopypi/forms.py b/djangopypi/forms.py index 1cf9a9d..1cf9a9d 100644 --- a/chishop/djangopypi/forms.py +++ b/djangopypi/forms.py | |||
diff --git a/chishop/djangopypi/models.py b/djangopypi/models.py index d66f5c8..d66f5c8 100644 --- a/chishop/djangopypi/models.py +++ b/djangopypi/models.py | |||
diff --git a/chishop/djangopypi/templates/djangopypi/show_links.html b/djangopypi/templates/djangopypi/show_links.html index b805f47..b805f47 100644 --- a/chishop/djangopypi/templates/djangopypi/show_links.html +++ b/djangopypi/templates/djangopypi/show_links.html | |||
diff --git a/chishop/djangopypi/templates/djangopypi/show_version.html b/djangopypi/templates/djangopypi/show_version.html index f0c9d75..f0c9d75 100644 --- a/chishop/djangopypi/templates/djangopypi/show_version.html +++ b/djangopypi/templates/djangopypi/show_version.html | |||
diff --git a/chishop/djangopypi/templates/djangopypi/simple.html b/djangopypi/templates/djangopypi/simple.html index de761a5..de761a5 100644 --- a/chishop/djangopypi/templates/djangopypi/simple.html +++ b/djangopypi/templates/djangopypi/simple.html | |||
diff --git a/chishop/djangopypi/views.py b/djangopypi/views.py index fc4061d..fc4061d 100644 --- a/chishop/djangopypi/views.py +++ b/djangopypi/views.py | |||
@@ -12,11 +12,11 @@ except ImportError: | |||
12 | 12 | ||
13 | setup( | 13 | setup( |
14 | name='chishop', | 14 | name='chishop', |
15 | version=__import__('chishop').__version__, | 15 | version=__import__('djangopypi').__version__, |
16 | description='Simple PyPI server written in Django.', | 16 | description='Simple PyPI server written in Django.', |
17 | author='Ask Solem', | 17 | author='Ask Solem', |
18 | author_email='askh@opera.com', | 18 | author_email='askh@opera.com', |
19 | packages=[], | 19 | packages=["djangopypi"], |
20 | install_requires=[ | 20 | install_requires=[ |
21 | 'django>=1.0', | 21 | 'django>=1.0', |
22 | ], | 22 | ], |