From: root Date: Mon, 14 Nov 2011 14:49:35 +0000 (+0200) Subject: Tools packaging. X-Git-Tag: pithos/v0.7.10~31 X-Git-Url: https://code.grnet.gr/git/pithos/commitdiff_plain/1ad8831f3965488f0cb95797956c47f462adfabc Tools packaging. Refs #1417 --- diff --git a/pithos/__init__.py b/pithos/__init__.py index df3f517..e69de29 100644 --- a/pithos/__init__.py +++ b/pithos/__init__.py @@ -1,34 +0,0 @@ -# Copyright 2011 GRNET S.A. All rights reserved. -# -# Redistribution and use in source and binary forms, with or -# without modification, are permitted provided that the following -# conditions are met: -# -# 1. Redistributions of source code must retain the above -# copyright notice, this list of conditions and the following -# disclaimer. -# -# 2. Redistributions in binary form must reproduce the above -# copyright notice, this list of conditions and the following -# disclaimer in the documentation and/or other materials -# provided with the distribution. -# -# THIS SOFTWARE IS PROVIDED BY GRNET S.A. ``AS IS'' AND ANY EXPRESS -# OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GRNET S.A OR -# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF -# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED -# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN -# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -# POSSIBILITY OF SUCH DAMAGE. -# -# The views and conclusions contained in the software and -# documentation are those of the authors and should not be -# interpreted as representing official policies, either expressed -# or implied, of GRNET S.A. - -__version__ = '0.7' diff --git a/pithos/backends/base.py b/pithos/backends/base.py index ee9ec58..fbf434c 100644 --- a/pithos/backends/base.py +++ b/pithos/backends/base.py @@ -294,6 +294,16 @@ class BaseBackend(object): """ return [] + def list_public(self, user, account, container): + """Return a list of object (name, version_id) tuples existing under a container and are public. + + Raises: + NotAllowedError: Operation not permitted + + NameError: Container does not exist + """ + return [] + def list_object_meta(self, user, account, container, until=None): """Return a list with all the container's object meta keys. diff --git a/setup.py b/setup.py index 8c18cba..2c05379 100644 --- a/setup.py +++ b/setup.py @@ -1,16 +1,25 @@ #!/usr/bin/env python -#from distutils.core import setup -from setuptools import setup +import os -from pithos import __version__ as version +from setuptools import setup, find_packages + +VERSION = os.popen("git describe --abbrev=0 --tags").read().strip(' \nv') setup( name='Pithos', - version=version, - description='Pithos file storage service', + version=VERSION, + description='Pithos file storage service and tools', author='GRNET', author_email='pithos@grnet.gr', url='http://code.grnet.gr/projects/pithos', packages=['pithos'], + license='BSD', + classifiers=[ + 'Development Status :: 3 - Alpha', + 'Operating System :: OS Independent', + 'Programming Language :: Python', + 'Topic :: Utilities', + 'License :: OSI Approved :: BSD License', + ] ) diff --git a/tools/MANIFEST.in b/tools/MANIFEST.in new file mode 100644 index 0000000..0c4b96b --- /dev/null +++ b/tools/MANIFEST.in @@ -0,0 +1 @@ +exclude lib/migrate* diff --git a/tools/README b/tools/README index a186bd6..2af25e6 100644 --- a/tools/README +++ b/tools/README @@ -1,4 +1,15 @@ -Tools in this dir depend on being able to import pithos. -You need to adjust PYTHONPATH accordingly for this to work. -e.g. - export PYTHONPATH=$HOME/src/pithos +README +====== + +Pithos is a file storage service, built by GRNET. +Learn more about Pithos at: http://code.grnet.gr/projects/pithos + +Here you will find the following tools: + + pithos-sh Pithos shell + pithos-sync Pithos synchronization client + pithos-fs Pithos FUSE implementation + +Also, the lib folder contains a python library that can be +used to access Pithos and manage stored objects. +All tools use the included lib. diff --git a/tools/storefs.py b/tools/pithos-fs similarity index 100% rename from tools/storefs.py rename to tools/pithos-fs diff --git a/tools/store b/tools/pithos-sh similarity index 100% rename from tools/store rename to tools/pithos-sh diff --git a/tools/psync b/tools/pithos-sync similarity index 100% rename from tools/psync rename to tools/pithos-sync diff --git a/tools/setup.py b/tools/setup.py new file mode 100644 index 0000000..cf40d4e --- /dev/null +++ b/tools/setup.py @@ -0,0 +1,26 @@ +#!/usr/bin/env python + +import os + +from setuptools import setup, find_packages + +VERSION = os.popen("git describe --abbrev=0 --tags").read().strip(' \nv') + +setup( + name='Pithos Tools', + version=VERSION, + description='Pithos file storage service tools', + author='GRNET', + author_email='pithos@grnet.gr', + url='http://code.grnet.gr/projects/pithos', + scripts=['pithos-sh', 'pithos-sync', 'pithos-fs'], + packages=['lib'], + license='BSD', + classifiers=[ + 'Development Status :: 3 - Alpha', + 'Operating System :: OS Independent', + 'Programming Language :: Python', + 'Topic :: Utilities', + 'License :: OSI Approved :: BSD License', + ] +)