-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathsetup.py
More file actions
executable file
·76 lines (65 loc) · 1.95 KB
/
setup.py
File metadata and controls
executable file
·76 lines (65 loc) · 1.95 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
72
73
74
75
76
#!/usr/bin/python
#
# Copyright 2018 British Broadcasting Corporation
#
# This is an internal BBC tool and is not licensed externally
# If you have received a copy of this erroneously then you do
# not have permission to reproduce it.
from __future__ import print_function
from setuptools import setup
import os
# Basic metadata
name = "nmosreverseproxy"
version = "0.6.0"
description = "Reverse Proxy Directory listing service and Apache 2 configuration for NMOS services"
url = 'https://github.com/bbc/nmos-reverse-proxy'
author = 'Simon Rankine'
author_email = 'Simon.Rankine@bbc.co.uk'
license = 'Apache 2'
long_description = description
def is_package(path):
return (
os.path.isdir(path) and os.path.isfile(os.path.join(path, '__init__.py'))
)
def find_packages(path, base=""):
""" Find all packages in path """
packages = {}
for item in os.listdir(path):
dir = os.path.join(path, item)
if is_package(dir):
if base:
module_name = "%(base)s.%(item)s" % vars()
else:
module_name = item
packages[module_name] = dir
packages.update(find_packages(dir, module_name))
return packages
packages = find_packages(".")
package_names = packages.keys()
# This is where you list packages which are required
packages_required = [
"six",
"nmoscommon"
]
# This is where you list locations for packages not
# available from pip. Each entry must be of the form:
# <url>#egg=<pkgname>=<version>
# eg. https://github.com/bbc/rd-apmm-python-lib-nmos-common#egg=nmoscommon=0.1.0
deps_required = []
setup(
name=name,
version=version,
description=description,
url=url,
author=author,
author_email=author_email,
license=license,
packages=package_names,
package_dir=packages,
install_requires=packages_required,
scripts=[],
data_files=[
('/usr/bin', ['bin/proxylisting'])
],
long_description=long_description
)