-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathsetup.py
More file actions
71 lines (61 loc) · 2.55 KB
/
setup.py
File metadata and controls
71 lines (61 loc) · 2.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#! /usr/bin/env python
# -*- coding:utf-8 -*-
# This file is a part of IoT-LAB aggregation-tools
# Copyright (C) 2015 INRIA (Contact: admin@iot-lab.info)
# Contributor(s) : see AUTHORS file
#
# This software is governed by the CeCILL license under French law
# and abiding by the rules of distribution of free software. You can use,
# modify and/ or redistribute the software under the terms of the CeCILL
# license as circulated by CEA, CNRS and INRIA at the following URL
# http://www.cecill.info.
#
# As a counterpart to the access to the source code and rights to copy,
# modify and redistribute granted by the license, users are provided only
# with a limited warranty and the software's author, the holder of the
# economic rights, and the successive licensors have only limited
# liability.
#
# The fact that you are presently reading this means that you have had
# knowledge of the CeCILL license and that you accept its terms.
""" Install some of the scripts.
Intended to be run on the ssh frontends """
import os
from setuptools import setup, find_packages
PACKAGE = 'iotlabaggregator'
SCRIPTS = ['serial_aggregator', 'sniffer_aggregator']
# GPL compatible http://www.gnu.org/licenses/license-list.html#CeCILL
LICENSE = 'CeCILL v2.1'
def get_version(package):
""" Extract package version without importing file
Importing cause issues with coverage,
(modules can be removed from sys.modules to prevent this)
Importing __init__.py triggers importing rest and then requests too
Inspired from pep8 setup.py
"""
with open(os.path.join(package, '__init__.py')) as init_fd:
for line in init_fd:
if line.startswith('__version__'):
version = eval(line.split('=')[-1]) # pylint:disable=eval-used
break
return version
setup(
name=PACKAGE,
version=get_version(PACKAGE),
description='IoT-LAB testbed node connection command-line tools',
author='IoT-LAB Team',
author_email='admin@iot-lab.info',
url='http://www.iot-lab.info',
license=LICENSE,
download_url='https://github.com/iot-lab/aggregation-tools',
packages=find_packages(),
scripts=SCRIPTS,
classifiers=['Programming Language :: Python',
'Programming Language :: Python :: 3',
'License :: OSI Approved',
'Intended Audience :: End Users/Desktop',
'Environment :: Console',
'Topic :: Utilities', ],
install_requires=['iotlabcli>=2.2.1', 'chardet', 'future'],
extras_require={'color_serial': ['colorama>=0.3.7']},
)