-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
75 additions
and
0 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,26 @@ | ||
name: Release | ||
on: | ||
push: | ||
tags: | ||
- '*' | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
- name: Set up Python | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: '3.6' | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install -r requirements.txt | ||
- name: Build and publish | ||
env: | ||
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} | ||
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} | ||
run: | | ||
python3 setup.py sdist bdist_wheel | ||
twine upload dist/* |
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,4 @@ | ||
pytest==6.2.5 | ||
setuptools==59.6.0 | ||
wheel==0.37.1 | ||
twine==3.8.0 |
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,46 @@ | ||
#!/usr/bin/env python3 | ||
import re | ||
|
||
from setuptools import setup | ||
|
||
with open('readme.md', 'r', encoding='utf-8') as f: | ||
README = f.read() | ||
|
||
with open('uaparser/__init__.py', 'r', encoding='utf-8') as f: | ||
VERSION = re.search(r"__version__ = '(.+)'", f.read()) \ | ||
.group(1) | ||
|
||
setup( | ||
name='ua-parser-py', | ||
version=VERSION, | ||
python_requires='>=3.6', | ||
description='Python library to detect Browser, Engine, OS, CPU, and Device type/model from User-Agent data', | ||
long_description=README, | ||
long_description_content_type='text/markdown', | ||
url='https://github.com/vitalibo/ua-parser-py', | ||
author='Vitaliy Boyarsky', | ||
author_email='boyarsky.vitaliy@live.com', | ||
license='MIT', | ||
classifiers=[ | ||
'Environment :: Web Environment', | ||
'Intended Audience :: Developers', | ||
'License :: OSI Approved :: MIT License', | ||
'Operating System :: OS Independent', | ||
'Programming Language :: Python', | ||
'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 :: Implementation :: CPython', | ||
'Programming Language :: Python :: Implementation :: PyPy', | ||
'Topic :: Internet :: WWW/HTTP', | ||
'Topic :: Software Development :: Libraries :: Python Modules', | ||
], | ||
keywords='user-agent parser browser engine os device cpu', | ||
packages=['uaparser'], | ||
data_files=[('', ['license.md', 'readme.md'])], | ||
zip_safe=False, | ||
install_requires=[], | ||
platforms='any' | ||
) |