Skip to content

Commit

Permalink
Merge pull request #2 from seasidesparrow/main
Browse files Browse the repository at this point in the history
 	new file:   setup.py
  • Loading branch information
seasidesparrow authored Feb 25, 2022
2 parents d930201 + 97a0c6e commit 794f6cc
Showing 1 changed file with 50 additions and 0 deletions.
50 changes: 50 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
import os
from subprocess import Popen, PIPE

try:
from setuptools import setup, find_packages
except ImportError:
from distutils.core import setup, find_packages

with open('requirements.txt') as f:
required = f.read().splitlines()


def get_git_version(default="v0.0.1"):
try:
p = Popen(['git', 'describe', '--tags'], stdout=PIPE, stderr=PIPE)
p.stderr.close()
line = p.stdout.readlines()[0]
line = line.strip()
return line.decode()
except:
return default

with open('README.md', 'r') as fd:
long_description = fd.read()

setup(
name='ingest_data_model',
version=get_git_version(default="v0.0.1"),
url='http://github.com/adsabs/ingest_data_model/',
license='MIT',
author='NASA/SAO ADS',
description='JSON Schema for ADS Ingest Data',
long_description=long_description,
long_description_content_type='text/markdown',
packages=find_packages(),
zip_safe=False,
include_package_data=True,
platforms='any',
install_requires=required,
classifiers=[
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.7',
'Topic :: Software Development :: Libraries :: Python Modules'
]
)

0 comments on commit 794f6cc

Please sign in to comment.