From b7872b45aa68a3323c859cdbdcb1a2d4c63ae25b Mon Sep 17 00:00:00 2001 From: Kelvin Law Date: Wed, 22 Aug 2012 17:11:35 -0700 Subject: [PATCH] Moved requirements into setup.py now that everything installs properly from just easystreet --- requirements.txt | 8 ---- scripts/install_python_packages.sh | 6 +-- setup.py | 75 +++++------------------------- 3 files changed, 13 insertions(+), 76 deletions(-) delete mode 100644 requirements.txt diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index fd8f75f..0000000 --- a/requirements.txt +++ /dev/null @@ -1,8 +0,0 @@ -# gingko -gevent==1.0b3 -ginkgo==twilio-rc2 -pytwilio.log -flask -#gevent-socketio -gevent-socketio-0.3.5 -requests diff --git a/scripts/install_python_packages.sh b/scripts/install_python_packages.sh index 9f2511f..60b8bbd 100755 --- a/scripts/install_python_packages.sh +++ b/scripts/install_python_packages.sh @@ -38,11 +38,7 @@ if [[ "$context" != testing ]]; then sleep 2 # hackery to wait until the pypi-server's actually started fi -#easy_install -i http://localhost:8302/simple/ gevent==1.0b3 -pip install -i http://localhost:8302/simple/ -r $dir/requirements.txt - -# pip install -i http://localhost:8302/simple/ -r $dir/requirements.txt -#pip install -r $dir/requirements.txt +pip install -i http://localhost:8302/simple/ . if [[ "$context" == testing ]]; then pip install -r $dir/tests/requirements.txt diff --git a/setup.py b/setup.py index 15a972f..4e80e54 100644 --- a/setup.py +++ b/setup.py @@ -2,67 +2,7 @@ # # $Id: $ -from setuptools import setup, Command, find_packages -# import os, shutil, stat, subprocess - -# def get_base_path(): -# """ -# Use this if you need to install any non-python files found inside the -# project tree -# """ -# return os.path.split(os.path.abspath(__file__))[0] - -# def get_python_bin_dir(): -# """ -# Use this if you need to install any files into the python bin dir -# """ -# return os.path.join(sys.prefix, 'bin') - -# def shell(cmdline): -# return subprocess.Popen(cmdline, shell=True).wait() - -# class TestCommand(Command): -# """ -# Run tests with nose -# """ -# description = "run tests with nose" -# def initialize_options(self): pass -# def finalize_options(self): pass -# user_options = [] - -# def run(self): -# shell("nosetests tests --with-coverage --cover-html") - -# class ServerSetup(Command): -# """ -# Install system level files (things that require escalated privs) -# """ -# description = "install system level files (init.d)" -# def initialize_options(self): pass -# def finalize_options(self): pass -# user_options = [] - -# def run(self): -# if os.getuid() != 0: -# print "You must be root to install server files." -# raise SystemExit(1) -# if not os.path.exists('/usr/local/sbin/pytwilio-runner'): -# print ("/usr/local/sbin/pytwilio-runner not installed, " -# "it is required for this server. Install it by doing" -# "sudo python setup.py server for pietwilio") -# raise SystemExit(1) -# print "installing /etc/init.d/shadow" -# shutil.copyfile(os.path.join(get_base_path(), "init.d", "shadow"), -# "/etc/init.d/shadow") -# os.chmod("/etc/init.d/shadow", 0755) - -# #copy the conf file to /etc/gservice, making gservice dir if it doesn't -# # exist -# print "installing /etc/gservice/shadow.conf.py" -# if not os.path.exists('/etc/gservice'): -# os.mkdir('/etc/gservice') -# shutil.copyfile(os.path.join(get_base_path(), "shadow.conf.py"), -# "/etc/gservice/shadow.conf.py") +from setuptools import setup, find_packages setup(name='shadow', version='0.1', @@ -72,6 +12,15 @@ packages = find_packages('src'), package_dir = {'': 'src'}, include_package_data = True, - # cmdclass={'test': TestCommand, - # 'server': ServerSetup} + install_requires = [ + # 3rd party + 'gevent==1.0b3', + 'ginkgo==twilio-rc2', + 'flask==0.9', + 'requests==0.13.6', + 'gevent-socketio==0.3.5-rc2', + + # internal dependencies + 'pytwilio.log==0.1', + ] )