Skip to content

Commit

Permalink
updating to work with PyPi distribution
Browse files Browse the repository at this point in the history
  • Loading branch information
matt snider committed Nov 2, 2012
1 parent eb5c5a3 commit 0dc11e9
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 25 deletions.
15 changes: 11 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
# OS files
*~
.DS_Store
*.pyc
*.egg

# IDE files
.idea

# python files
*.pyc
*.coverage
build/

# build files
*.egg
MANIFEST
dist/
dist/
build/
1 change: 1 addition & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v0.1.3, 11/2/2012 -- Initial release.
File renamed without changes.
2 changes: 2 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
include *.txt
include *.md
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Getting started

Standard stuff applies to install. Use PIP to install with dependencies:

pip install git+https://github.com/mattsnider/Django-Simple-Social.git#egg=django_simple_social
pip install django-simple-social

Or install from the command line:

Expand Down
2 changes: 1 addition & 1 deletion django_simple_social/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
__author__ = 'mattesnider'

__version__ = (0, 1, 2)
__version__ = (0, 1, 3)


def autodiscover():
Expand Down
8 changes: 0 additions & 8 deletions requirements.pip

This file was deleted.

23 changes: 12 additions & 11 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,9 @@

ROOT_DIR = os.path.abspath(os.path.dirname(__file__))

def get_deps():
f = open(os.path.join(ROOT_DIR, "requirements.pip"), 'r')
return [l[:-1] for l in f.readlines()]

# README is required for distribution, but README.md is required for github,
# so create README temporarily
is_distribution = 'sdist' in sys.argv or 'bdist_wininst' in sys.argv

if is_distribution:
os.system('cp %s/README.md %s/README' % (ROOT_DIR, ROOT_DIR))
os.system('cp %s/README.md %s/README.txt' % (ROOT_DIR, ROOT_DIR))

sdict = dict(
name = 'django-simple-social',
Expand All @@ -28,7 +21,16 @@ def get_deps():
maintainer_email = 'admin@mattsnider.com',
keywords = ['simple', 'social', 'linkedin', 'facebook', 'twitter'],
license = 'MIT',
install_requires=get_deps(),
install_requires=[
# framework required for work with this library
'django>=1.3',

# social infrastructure library
'django-social-user',

# social network libraries
'linkedin-api-json-client'
],
classifiers=[
'Programming Language :: Python',
'License :: OSI Approved :: MIT License',
Expand All @@ -44,5 +46,4 @@ def get_deps():
setup(**sdict)

# cleanup README
if is_distribution:
os.remove('%s/README' % ROOT_DIR)
os.remove('%s/README.txt' % ROOT_DIR)

0 comments on commit 0dc11e9

Please sign in to comment.