From 50453885291f5c5341ceb3a732be9a068873cffe Mon Sep 17 00:00:00 2001 From: Valerii Ponomarov Date: Tue, 26 Nov 2019 21:28:20 +0530 Subject: [py2to3] Fix files located in the 'glustolibs-io' dir Do following things in the files from the mentioned directory: - Make it be python 2/3 compatible. - Fix pep8 issues. - Place imports in alphabetical order. - Improve some parts for the better readability. - Add comma separators in the setup.py for it's classifiers. Before it was mistakenly made as one long line. Change-Id: I3f0a5921a5386275a8a35bf2f22ee3952700e490 Signed-off-by: Valerii Ponomarov --- glustolibs-io/setup.py | 34 ++++++++++++++++++++-------------- 1 file changed, 20 insertions(+), 14 deletions(-) (limited to 'glustolibs-io/setup.py') diff --git a/glustolibs-io/setup.py b/glustolibs-io/setup.py index 41655dad6..4e3b16e89 100644 --- a/glustolibs-io/setup.py +++ b/glustolibs-io/setup.py @@ -1,4 +1,4 @@ -#!/usr/bin/python +#!/usr/bin/env python # Copyright (c) 2016 Red Hat, Inc. # # This program is free software; you can redistribute it and/or modify @@ -15,9 +15,11 @@ # with this program; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. # + +from distutils import dir_util import os + from setuptools import setup, find_packages -from distutils import dir_util version = '0.1.2' name = 'glustolibs-io' @@ -32,23 +34,27 @@ setup( url='http://www.gluster.org', packages=find_packages(), classifiers=[ - 'Development Status :: 4 - Beta' - 'Environment :: Console' - 'Intended Audience :: Developers' - 'License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)' - 'Operating System :: POSIX :: Linux' - 'Programming Language :: Python' - 'Programming Language :: Python :: 2' - 'Programming Language :: Python :: 2.6' - 'Programming Language :: Python :: 2.7' - 'Topic :: Software Development :: Testing' + 'Development Status :: 4 - Beta', + 'Environment :: Console', + 'Intended Audience :: Developers', + 'License :: OSI Approved :: GNU General Public License v2 or ' + 'later (GPLv2+)', + 'Operating System :: POSIX :: Linux', + 'Programming Language :: Python', + 'Programming Language :: Python :: 2', + 'Programming Language :: Python :: 2.6', + 'Programming Language :: Python :: 2.7', + 'Programming Language :: Python :: 3', + 'Topic :: Software Development :: Testing', ], install_requires=['glusto'], - dependency_links=['http://github.com/loadtheaccumulator/glusto/tarball/master#egg=glusto'], + dependency_links=[ + 'http://github.com/loadtheaccumulator/glusto/tarball/master#egg=glusto' + ], namespace_packages = ['glustolibs'] ) try: dir_util.copy_tree('./shared_files', '/usr/share/glustolibs/io') -except: +except Exception: pass -- cgit