Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
language: python

sudo: false # Since this is an older project, this is not the default.
cache: pip
dist: xenial
python:
- "2.7"
- "3.4"
- "3.5"
- "3.6"

- "3.7"
install:
- pip install -U tox-travis

- pip install -U pip setuptools
- pip install tox-travis
script:
- tox

notifications:
email:
- stix-commits-list@groups.mitre.org
2 changes: 2 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[bdist_wheel]
universal = True
31 changes: 18 additions & 13 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Copyright (c) 2018 - The MITRE Corporation
# For license information, see the LICENSE.txt file

from io import open # Allow `encoding` kwarg on Python 2.7

from os.path import abspath, dirname, join


Expand All @@ -12,6 +12,7 @@
BASE_DIR = dirname(abspath(__file__))
VERSION_FILE = join(BASE_DIR, 'maec', 'version.py')


def get_version():
with open(VERSION_FILE) as f:
for line in f.readlines():
Expand All @@ -21,14 +22,16 @@ def get_version():
raise AttributeError("Package does not have a __version__")


with open('README.rst', encoding='utf-8') as f:
readme = f.read()
def get_long_description():
with open('README.rst') as f:
return f.read()


install_requires = [
'lxml>=2.2.3',
'mixbox>=0.0.13',
'cybox>=2.1.0.13.dev1,<2.1.1.0',
'lxml>=2.2.3 ; python_version == "2.7" or python_version >= "3.5"',
'lxml>=2.2.3,<4.4.0 ; python_version > "2.7" and python_version < "3.5"',
'mixbox>=1.0.2',
'cybox>=2.1.0.13,<2.1.1.0',
]

extras_require = {
Expand All @@ -48,18 +51,20 @@ def get_version():
author="MAEC Project",
author_email="maec@mitre.org",
description="An API for parsing and creating MAEC content.",
long_description=readme,
long_description=get_long_description(),
url="http://maec.mitre.org",
packages=find_packages(),
install_requires=install_requires,
extras_require=extras_require,
license="BSD",
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
Expand Down
9 changes: 6 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
[tox]
envlist = py27,py34,py35,py36
envlist = py27,py34,py35,py36,py37

[testenv]
commands =
nosetests maec
sphinx-build -b doctest docs docs/_build/doctest
sphinx-build -b html docs docs/_build/html
deps =
-rrequirements.txt

[testenv:docs]
commands =
sphinx-build -W -b doctest -d {envtmpdir}/doctrees docs {envtmpdir}/doctest
sphinx-build -W -b html -d {envtmpdir}/doctrees docs {envtmpdir}/html

[travis]
python =
2.7: py27
3.4: py34
3.5: py35
3.6: py36
3.7: py37