From 2406c34d0bae75a14d75662a5f8b53a3e0dc8430 Mon Sep 17 00:00:00 2001 From: Serapheim Dimitropoulos Date: Tue, 17 Mar 2020 22:29:47 +0000 Subject: [PATCH] setup.py: add standard fields and fix any references to sdimitro repo setup.py: add dependencies in setup.py and point requirements.txt to it github actions: add testing for creating distribution archives --- .github/workflows/main.yml | 23 ++++++++++++++++++++--- README.md | 2 +- requirements.txt | 1 + setup.py | 35 +++++++++++++++++++---------------- 4 files changed, 41 insertions(+), 20 deletions(-) create mode 100644 requirements.txt diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b61512c7..d505124b 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -20,9 +20,14 @@ jobs: python-version: ${{ matrix.python-version }} - run: python3 setup.py install # - # The statement below is used for debugging the Github job. + # The statements below are used for debugging the Github job: + # - Ensure that we are using the right python version from + # the Github action matrix. + # - Ensure that drgn (the main dependency of sdb) is installed + # as part of `setup.py install`. # - run: python3 --version + - run: drgn -h # # Verify "pylint" runs successfully. # @@ -80,8 +85,7 @@ jobs: with: python-version: '3.6' - run: python3 -m pip install yapf - - run: yapf --diff --style google --recursive sdb - - run: yapf --diff --style google --recursive tests + - run: yapf --diff --style google --recursive sdb tests setup.py # # Verify "mypy" runs successfully. # @@ -120,3 +124,16 @@ jobs: - uses: actions/checkout@v2 - run: ./.github/scripts/install-shfmt.sh - run: /usr/local/bin/shfmt -d . + # + # Verify that we can generate a new distribution archive. + # + distribution-archives: + runs-on: ubuntu-18.04 + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-python@v1 + with: + python-version: '3.6' + - run: python3 -m pip install --user --upgrade setuptools wheel + - run: python3 setup.py sdist bdist_wheel + - run: ls dist diff --git a/README.md b/README.md index 393797ef..0d0f9794 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # sdb -The Slick/Simple Debugger +The Slick Debugger ![](https://github.com/delphix/sdb/workflows/.github/workflows/main.yml/badge.svg) diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 00000000..9c558e35 --- /dev/null +++ b/requirements.txt @@ -0,0 +1 @@ +. diff --git a/setup.py b/setup.py index 46eeff50..0075cfff 100755 --- a/setup.py +++ b/setup.py @@ -2,30 +2,33 @@ from setuptools import setup, find_packages +with open("README.md", "r") as f: + long_description = f.read() + setup( name='sdb', version="0.1.0", - - packages=[ - "sdb", - "sdb.commands", - "sdb.commands.internal", - "sdb.commands.linux", - "sdb.commands.linux.internal", - "sdb.commands.spl", - "sdb.commands.spl.internal", - "sdb.commands.zfs", - "sdb.commands.zfs.internal", - "sdb.internal", + python_requires='>=3.6', + packages=find_packages(), + install_requires=[ + 'drgn>=0.0.3', ], - entry_points={ 'console_scripts': ['sdb=sdb.internal.cli:main'], }, - author='Delphix Platform Team', author_email='serapheim@delphix.com', - description='The Slick/Simple Debugger', + description='The Slick Debugger', + long_description=long_description, + long_description_content_type="text/markdown", + url='https://github.com/delphix/sdb', license='Apache-2.0', - url='https://github.com/sdimitro/sdb', + classifiers=[ + "Development Status :: 3 - Alpha", + "License :: OSI Approved :: Apache Software License", + "Operating System :: POSIX :: Linux", + "Programming Language :: Python :: 3", + "Topic :: Software Development :: Debuggers", + "Topic :: System :: Operating System Kernels :: Linux", + ], )