#!/usr/bin/env python
#    gRefer is a Bibliographic Management System that uses Google Docs
#    as shared storage.
#
#    Copyright (C) 2011  NigelB
#
#    This program is free software: you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation, either version 3 of the License, or
#    (at your option) any later version.
#
#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with this program.  If not, see <http://www.gnu.org/licenses/>.

import os
from distutils.core import setup



def get_packages_dirs(start):
    toRet = [start]
    for dir, subdirs, files  in os.walk(start):
        for subdir in subdirs:
            if subdir != "test_data":
                toRet.append(os.path.join(dir,subdir))
    return toRet

setup(name='gRefer',
      version='0.1',
      description='Bibliographic management using Google Docs as a shared storage',
      author='NigelB',
      author_email='nigel.blair+grefer@gmail.com',
      url='http://github.com/nigelb/gRefer/',
      packages=get_packages_dirs("gRefer"),
      package_dir={'gRefer.conv.internal': 'gRefer/conv/internal'},
      package_data={'gRefer.conv.internal': ['bibtex/test_data/*.*', 'ris/test_data/*.*']},
      scripts=['bin/gref', 'bin/bibfiler', 'bin/bib-notifier'],
      data_files=[('/usr/share/pixmaps/grefer/icons',['icons/bulb.png'])],
      requires=["simpleui", "gdata_utils","requests", "dbus", "rdflib", "pyparsing", "pynotify"],
     )

