From 34b7ba80308075e19ec528ae7f5a1de7ef53cd1e Mon Sep 17 00:00:00 2001 From: Junpei Kawamoto Date: Thu, 26 Jan 2017 12:26:44 -0500 Subject: [PATCH] Update package information. --- README.md | 2 ++ README.rst | 50 ++++++++++++++++++++++++++++++++++++++++++++++++ requirements.in | 2 +- requirements.txt | 6 +++--- setup.py | 35 +++++++++++++++------------------ 5 files changed, 71 insertions(+), 24 deletions(-) create mode 100644 README.rst diff --git a/README.md b/README.md index b6d6453..a55037c 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,8 @@ [![Release](https://img.shields.io/badge/release-0.9.5-brightgreen.svg)](https://github.com/rgmining/fraud-eagle/releases/tag/v0.9.5) [![Japanese](https://img.shields.io/badge/qiita-%E6%97%A5%E6%9C%AC%E8%AA%9E-brightgreen.svg)](http://qiita.com/jkawamoto/items/d2284316cc37cd810bfd) +[![Logo](https://rgmining.github.io/fraud-eagle/_static/image.png)](https://rgmining.github.io/fraud-eagle/) + This package provides an implementation of Fraud Eagle algorithm. This algorithm has been introduced by Leman Akoglu, *et al.* in [ICWSM 2013](https://www.aaai.org/ocs/index.php/ICWSM/ICWSM13/paper/viewFile/5981/6338) diff --git a/README.rst b/README.rst new file mode 100644 index 0000000..a3c040f --- /dev/null +++ b/README.rst @@ -0,0 +1,50 @@ +Fraud Eagle Algorithm +===================== + +| |GPLv3| +| |Build Status| +| |wercker status| +| |Code Climate| +| |Release| +| |Japanese| + +|Logo| + +| This package provides an implementation of Fraud Eagle algorithm. +| This algorithm has been introduced by Leman Akoglu, *et al.* in +| `ICWSM + 2013 `__ + +See `the documents `__ for more +information. + +Installation +------------ + +Use ``pip`` to install this package. + +:: + + pip install --upgrade rgmining-fraud-eagle + +License +------- + +| This software is released under The GNU General Public License Version + 3, +| see `COPYING `__ for more detail. + +.. |GPLv3| image:: https://img.shields.io/badge/license-GPLv3-blue.svg + :target: https://www.gnu.org/copyleft/gpl.html +.. |Build Status| image:: https://travis-ci.org/rgmining/fraud-eagle.svg?branch=master + :target: https://travis-ci.org/rgmining/fraud-eagle +.. |wercker status| image:: https://app.wercker.com/status/fb1061f0043991bf7609a198a96acbaf/s/master + :target: https://app.wercker.com/project/byKey/fb1061f0043991bf7609a198a96acbaf +.. |Code Climate| image:: https://codeclimate.com/github/rgmining/fraud-eagle/badges/gpa.svg + :target: https://codeclimate.com/github/rgmining/fraud-eagle +.. |Release| image:: https://img.shields.io/badge/release-0.9.5-brightgreen.svg + :target: https://github.com/rgmining/fraud-eagle/releases/tag/v0.9.5 +.. |Japanese| image:: https://img.shields.io/badge/qiita-%E6%97%A5%E6%9C%AC%E8%AA%9E-brightgreen.svg + :target: http://qiita.com/jkawamoto/items/d2284316cc37cd810bfd +.. |Logo| image:: https://rgmining.github.io/fraud-eagle/_static/image.png + :target: https://rgmining.github.io/fraud-eagle/ diff --git a/requirements.in b/requirements.in index ff4db03..eb94dc9 100644 --- a/requirements.in +++ b/requirements.in @@ -1,3 +1,3 @@ networkx numpy --e git+https://github.com/rgmining/common#egg=rgmining-common-master +rgmining-common diff --git a/requirements.txt b/requirements.txt index f3abfba..a63fa2b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,7 +4,7 @@ # # pip-compile --output-file requirements.txt requirements.in # -decorator>=4.0.10 # via networkx +decorator>=4.0.11 # via networkx networkx>=1.11 -numpy>=1.11.1 --e git+https://github.com/rgmining/common#egg=rgmining-common-master +numpy>=1.12.0 +rgmining-common>=0.9.0 diff --git a/setup.py b/setup.py index 2757968..955b0b5 100644 --- a/setup.py +++ b/setup.py @@ -1,7 +1,7 @@ # # setup.py # -# Copyright (c) 2016 Junpei Kawamoto +# Copyright (c) 2016-2017 Junpei Kawamoto # # This file is part of rgmining-fraud-eagle. # @@ -16,7 +16,7 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with Foobar. If not, see . +# along with rgmining-fraud-eagle. If not, see . # # pylint: skip-file """Package information of fraud_eagle package for review graph mining project. @@ -24,43 +24,38 @@ from setuptools import setup, find_packages -def take_package_name(name): - """Returns a package name. +def read(fname): + """Read a file. """ - if name.startswith("-e"): - return name[name.find("=")+1:name.rfind("-")] - else: - return name.strip() + return open(path.join(path.dirname(__file__), fname)).read() def load_requires_from_file(filepath): """Read a package list from a given file path. - """ - with open(filepath) as fp: - return [take_package_name(pkg_name) for pkg_name in fp.readlines()] + Args: + filepath: file path of the package list. -def load_links_from_file(filepath): - """Read a package list and returns links. + Returns: + a list of package names. """ - res = [] with open(filepath) as fp: - for pkg_name in fp.readlines(): - if pkg_name.startswith("-e"): - res.append(pkg_name.split(" ")[1]) - return res + return [pkg_name.strip() for pkg_name in fp.readlines()] setup( name='rgmining-fraud-eagle', - version='0.9.5', + use_scm_version=True, author="Junpei Kawamoto", author_email="kawamoto.junpei@gmail.com", description="An implementation of Fraud Eagle algorithm", + long_description=read("README.rst"), url="https://github.com/rgmining/frad-eagle", packages=find_packages(exclude=["tests"]), + setup_requires=[ + "setuptools_scm" + ], install_requires=load_requires_from_file("requirements.txt"), - dependency_links=load_links_from_file("requirements.txt"), test_suite='tests.suite', license="GPLv3", classifiers=[