forked from sassoftware/python-keyutils
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add workflows and expand supported pythons
Feature/more pythons
- Loading branch information
Showing
9 changed files
with
246 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
[paths] | ||
source = | ||
keyutils | ||
*/site-packages | ||
|
||
[run] | ||
branch = true | ||
source = | ||
keyutils | ||
parallel = true | ||
|
||
[report] | ||
show_missing = true | ||
precision = 2 | ||
omit = *migrations* | ||
exclude_lines = | ||
if __name__ == .__main__.: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: Tests | ||
|
||
on: | ||
push: | ||
branches: [main, master] | ||
pull_request: | ||
branches: [main, master] | ||
|
||
|
||
jobs: | ||
build: | ||
runs-on: ${{ matrix.platform }} | ||
strategy: | ||
matrix: | ||
platform: ["ubuntu-20.04"] | ||
python-version: ["2.7", "3.5", "3.6", "3.7", "3.8", "3.9", "3.10"] | ||
include: | ||
- platform: "ubuntu-18.04" | ||
python-version: "2.7" | ||
# - platform: "ubuntu-18.04" | ||
# python-version: "3.4" | ||
- platform: "ubuntu-18.04" | ||
python-version: "3.6" | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install C dependencies | ||
run: | | ||
sudo apt-get install -y keyutils libkeyutils-dev | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip setuptools wheel | ||
pip install coverage[toml] virtualenv tox tox-gh-actions | ||
- name: Test with tox | ||
run: tox | ||
#env: | ||
# PLATFORM: ${{ matrix.platform }} | ||
|
||
# from https://github.com/codecov/codecov-action | ||
- name: Upload coverage to Codecov | ||
uses: codecov/codecov-action@v2 | ||
with: | ||
files: ./coverage.xml | ||
fail_ci_if_error: true | ||
verbose: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Lint tests run on PR | ||
# but should not run after push to main because reporting | ||
# these after push is meaningless to the building of the package | ||
name: lint | ||
|
||
on: | ||
pull_request: | ||
branches: [main, master] | ||
|
||
jobs: | ||
build: | ||
runs-on: ${{ matrix.platform }} | ||
strategy: | ||
matrix: | ||
platform: [ubuntu-latest] | ||
python-version: ["2.7", "3.6", "3.10"] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install C dependencies | ||
run: | | ||
sudo apt-get install -y keyutils libkeyutils-dev | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip setuptools wheel | ||
pip install virtualenv tox tox-gh-actions | ||
- name: Test Lint | ||
run: tox -e lint,radon |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
include AUTHORS ChangeLog INSTALL LICENSE README.rst TODO | ||
include keyutils/_keyutils.c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,21 +17,23 @@ | |
|
||
|
||
import io | ||
from setuptools import setup, Extension | ||
|
||
with io.open('README.rst', "r", encoding="utf-8") as f: | ||
from setuptools import Extension, setup | ||
|
||
|
||
with io.open("README.rst", "r", encoding="utf-8") as f: | ||
long_description = f.read() | ||
|
||
setup( | ||
name='keyutils', | ||
version='0.6', | ||
description='keyutils bindings for Python', | ||
name="keyutils", | ||
version="0.6", | ||
description="keyutils bindings for Python", | ||
long_description=long_description, | ||
author='Mihai Ibanescu', | ||
author_email='[email protected]', | ||
url='https://github.com/sassoftware/python-keyutils', | ||
license='Apache 2.0', | ||
packages=['keyutils'], | ||
author="Mihai Ibanescu", | ||
author_email="[email protected]", | ||
url="https://github.com/sassoftware/python-keyutils", | ||
license="Apache 2.0", | ||
packages=["keyutils"], | ||
classifiers=[ | ||
"Topic :: Security", | ||
"Operating System :: POSIX :: Linux", | ||
|
@@ -41,17 +43,21 @@ | |
"Programming Language :: Python :: 3.5", | ||
"Programming Language :: Python :: 3.6", | ||
"Programming Language :: Python :: 3.7", | ||
], | ||
"Programming Language :: Python :: 3.8", | ||
"Programming Language :: Python :: 3.9", | ||
"Programming Language :: Python :: 3.10", | ||
"Programming Language :: Python :: 3.11", | ||
], | ||
platforms=[ | ||
"Linux", | ||
], | ||
], | ||
ext_modules=[ | ||
Extension( | ||
'keyutils._keyutils', | ||
['keyutils/_keyutils.pyx'], | ||
libraries=['keyutils'], | ||
"keyutils._keyutils", | ||
["keyutils/_keyutils.pyx"], | ||
libraries=["keyutils"], | ||
), | ||
], | ||
setup_requires=["pytest-runner"], | ||
tests_require=["pytest"], | ||
setup_requires=[], | ||
tests_require=["pytest", "pytest-runner"], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.